From 3c82a74fba0dd1434c3582cbb3b77e1c2a2acd7c Mon Sep 17 00:00:00 2001 From: Brandon Corfman Date: Sat, 1 Nov 2025 13:55:27 -0400 Subject: [PATCH] Handle missing ControllerWindow --- game/play.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/game/play.py b/game/play.py index 8ae0011..0adaa5c 100644 --- a/game/play.py +++ b/game/play.py @@ -76,7 +76,8 @@ class Game(arcade.gui.UIView): self.save_button.on_click = lambda event: self.save() self.anchor.add(self.save_button, anchor_x="right", anchor_y="bottom", align_x=-5, align_y=5) - if self.window.get_controllers(): + # Check if window has controller support (ControllerWindow has get_controllers, regular Window doesn't) + if hasattr(self.window, 'get_controllers') and self.window.get_controllers(): self.spritelist = arcade.SpriteList() self.cursor_sprite = arcade.Sprite(cursor_texture) self.spritelist.append(self.cursor_sprite)