Mehr Logik

This commit is contained in:
Lena committed 2026-10-28 23:55:35 +01:00
1 parent 5e063d06b1
commit 3e32a54909
3 files changed
+37 -4

No files matched your search

+32
View File
@@ -0,0 +1,32 @@
from spiel.game import Game
class CubeGame(Game):
"""A simple 3D cube game demo."""
def __init__(self):
super().__init__("3D Cube", 60, (640, 480))
self.corners = [[-1, -1, -1], [ 1, -1, -1], [ 1, 1, -1], [-1, 1, -1],[-1, -1, 1], [ 1, -1, 1], [ 1, 1, 1], [-1, 1, 1]]
self.angle_x = 0
self.angle_y = 0
self.edges = [
(0, 1),
(1, 2),
(2, 3),
(3, 0),
(4, 5),
(5, 6),
(6, 7),
(7, 4),
(0, 4),
(1, 5),
(2, 6),
(3, 7),
]
def update_game(self) -> bool:
# No logic yet, just keep running
return True
def draw_game(self) -> None:
# Clear screen to black
self.screen.fill((0, 0, 0))