generated from mwc/project_game
added demo game in chris_demo
You had some really clear planning in your commit message-- In the "chris_demo" folder I implemented a bunch of what you planned. I suggest playing the game I built (go into chris_demo and run python game.py), and then carefully reading all the source code. Then, if you like the patterns I used, copy or move whatever you want to use into your main project folder. Also, if there are parts of my code you don't understand, please let me know (in a commit message or in person next time I'm in class) and I'll be happy to explain it.
This commit is contained in:
11
chris_demo/game.py
Normal file
11
chris_demo/game.py
Normal file
@@ -0,0 +1,11 @@
|
||||
from retro.game import Game
|
||||
from dealer import Dealer
|
||||
|
||||
dealer = Dealer((1, 1))
|
||||
state = {
|
||||
"score": 0,
|
||||
"options": "h to hit or s to stay",
|
||||
}
|
||||
game = Game([dealer], state)
|
||||
game.play()
|
||||
|
||||
Reference in New Issue
Block a user