changeset 467:04127e7219cd

More object checks
author Neil Muller <drnlmuller@gmail.com>
date Sat, 07 Sep 2013 16:21:03 +0200
parents f66e88d449a7
children 149fbde0e692 82db70c28722
files tools/area_editor.py
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/tools/area_editor.py	Sat Sep 07 16:11:39 2013 +0200
+++ b/tools/area_editor.py	Sat Sep 07 16:21:03 2013 +0200
@@ -210,6 +210,11 @@
         try:
             target.append(new)
             self.reset_objs()
+            test_surface = pygame.surface.Surface((self.x, self.y))
+            # Check for initialisation stuff that happens in render
+            for thing in self.drawables:
+                if not isinstance(thing, ne.Enemy):
+                    thing.render(test_surface)
             return True
         except Exception as e:
             target.remove(new)