-
Notifications
You must be signed in to change notification settings - Fork 10
GameState Tutorial
David Churchill edited this page Mar 20, 2020
·
1 revision
The main class in the Prismata AI Engine is the GameState class, which handles all of the game logic and storage of Card data. I have not yet written a full tutorial for this class, but you can see plenty of sample code in the project. Here are some examples from the current system's AI player functions:
- Iterating through GameState legal actions and issuing random actions
- Iterating over GameState and activating all units
- Activating only Drones
- Activating all Attacking units
- Activating everything except Attacking units
- Sniping the highest priced enemy units
- Chilling enemy units using a greedy knapsack solver
- Untapping units to avoid getting breached
- Buy whatever we can in the order we iterate through
- Buy random cards until we can't afford any more
- Buy cards using the AI config opening book