Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement basic game logic #1

Open
Mystri opened this issue Feb 12, 2022 · 2 comments
Open

Implement basic game logic #1

Mystri opened this issue Feb 12, 2022 · 2 comments
Labels

Comments

@Mystri
Copy link
Collaborator

Mystri commented Feb 12, 2022

Finish basic game logic.
Here's @rishisek 's comment on the logic, basically what we expect for a turn to do.

    /**
     * A single turn:
     * - Use
     * - Move
     * - Attack
     * - Buy
     *
     * DecisionSet becomes a compilation of these 4. At the end of a turn, decision_set is written to JSON.
     *
     * Turn {
     * players: [
     *  Player {
     *    // state
     *  }
     * ],
     * decision_sets: [
     *  DecisionSet {
     *    use, move, attack, buy
     *  }
     * ]
     * }
     */

    /*
    1. Create GameState
    2. For each turn of game,
        a. execute use, move, ...
        b. render turn
     */
@Mystri
Copy link
Collaborator Author

Mystri commented Feb 12, 2022

Start by designing and writing unit tests for each action. We will go through the design part in today's meeting.

Designing:

Unit Tests Written:

  • AttackAction
  • BuyAction
  • MoveAction
  • UseAction

After finishing tests for the actions and finished #2 , write unit tests for final results.

  • Main

@Mystri Mystri added good first issue Good for newcomers alpha and removed good first issue Good for newcomers labels Feb 12, 2022
@Mystri
Copy link
Collaborator Author

Mystri commented Feb 19, 2022

This will be closed after the unit testings and implementations are done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant