Yo1k / tic-tac-toe

A multiplayer turn-based game
MIT License
0 stars 0 forks source link

Store `PlayerID` in `State.board` instead of storing `Mark` #24

Open stIncMale opened 2 years ago

stIncMale commented 2 years ago

Originally Mark was intended to effectively identify a player. Now we have PlayerID for that, and Mark is not needed anymore, given that we don't allow players to choose marks (we can just use x for playero, and o for player1).

Implementing this issue includes renaming player_x/player_y/act_queue_px/etc. to player_0/player_1/act_queue_p0, for example, in test/test_game.py. It also makes expressions like state.players[1].id meaningless, requiring them to be replaced with 1.

Note: done in Rust.