From 5c5ed49a9bb78409aa8c47ff4213c3629bf75225 Mon Sep 17 00:00:00 2001 From: EKNr1 Date: Thu, 18 Apr 2024 18:30:13 +0200 Subject: [PATCH] Added update function to not have to call Object.rotate_sprites() and Object.generate_surface(). --- engine.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/engine.py b/engine.py index de2eec3..1f9bd1c 100644 --- a/engine.py +++ b/engine.py @@ -58,6 +58,9 @@ class Object: return surface + def update(self): + return self.rotate_sprites(), self.generate_surface() + def get_dir(path: str): return path.rsplit("/", 1)[0]