Skip to content

ronchen0927/Django_Shogi

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

39 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Django Shogi

Introduction

Game rules


Initial board

9 | L| N| S| G| K| G| S| N| L|
8 |__| R|__|__|__|__|__| B|__|
7 | P| P| P| P| P| P| P| P| P|
6 |__|__|__|__|__|__|__|__|__|
5 |__|__|__|__|__|__|__|__|__|
4 |__|__|__|__|__|__|__|__|__|
3 | p| p| p| p| p| p| p| p| p|
2 |__| b|__|__|__|__|__| r|__|
1 | l| n| s| g| k| g| s| n| l|
    a  b  c  d  e  f  g  h  i

Our Captures:
Opponent Captures:

我方玩家: foo
敵方玩家: bar

Usage

Install requirement

pip install -r requirements.txt

Make migrations to the model

python manage.py makemigrations
python manage.py migrate

WebScoket: Open redis for Django channel layer

docker run --rm -p 6379:6379 redis:7

Runserver

python manage.py runserver

API doc

http://127.0.0.1:8000/swagger/


How to Play

You need two players to start the game

One player creates a game(建立新遊戲) and another player joins the game(加入遊戲) And you can continue playing game(繼續遊戲) until it is finished

Move

Move piece a3 to a4

a3a4

Promotion move

Move piece h6 to h7 and promote

h6h7+

Drop

Our player drop "Pawn" to d4

P*d4

Opponent player drop "Rook" to g5

r*g5

About

Shogi server built with Django

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published