@chris My fruit offset does not work

This commit is contained in:
kdang
2026-01-09 09:49:15 -05:00
parent d6adfef5a1
commit 267fffa9b0
9 changed files with 69 additions and 54 deletions

16
game.py
View File

@@ -1,20 +1,16 @@
from random import randint
from retro.game import Game
from retro.graph import Graph
from catcher import Catcher
from fruit import Fruit
from manager import FruitManager
g = Graph()
g.get_or_create_edge(26, 10, 26, 22)
agents = g.get_agents()
for agent in agents:
agent.color = "white_on_indigo"
WIDTH = 27
HEIGHT = 30
agents = [
Catcher((14, 24)),
Fruit((14, 2)),
Catcher((11, 29)),
FruitManager(),
]
state = {'Score': 0}
game = Game(agents, state, board_size=(35, 25), framerate=24, color="white_on_indigo")
game = Game(agents, state, board_size=(WIDTH, HEIGHT), framerate=24, color="white_on_indigo")
game.play()