Ignore:
Timestamp:
09/03/13 18:24:25 (8 years ago)
Author:
Jeremy Thurgood <firxen@…>
Branch:
default
Phase:
public
Message:

Better collision handling, potentially locked doors.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • nagslang/game_object.py

    r186 r188  
    435435        )
    436436
    437     def animate(self):
    438         space = self.get_space()
    439         for shape in space.shape_query(self.get_shape()):
    440             if shape.collision_type == COLLISION_TYPE_PLAYER:
    441                 # Force to new position
    442                 DoorEvent.post(self.destination, self.dest_pos)
     437    def collide_with_protagonist(self):
     438        if self.puzzler.get_state():
     439            DoorEvent.post(self.destination, self.dest_pos)
Note: See TracChangeset for help on using the changeset viewer.