Changeset 94:75fa8d6fbf49


Ignore:
Timestamp:
Apr 4, 2011, 3:22:47 PM (9 years ago)
Author:
Neil Muller <drnlmuller@…>
Branch:
default
Message:

Add defaults for player info in level load

File:
1 edited

Legend:

Unmodified
Added
Removed
  • skaapsteker/level.py

    r88 r94  
    9090    def setup_player(self, player):
    9191        player_data = self.level_data['player']
    92         player.set_facing(player_data.pop('direction'))
     92        player.set_facing(player_data.pop('direction', 'left'))
    9393        player.set_image()
    94         player.set_pos(player_data.pop('pos'))
     94        player.set_pos(player_data.pop('pos', (5, 5)))
    9595        self.sprites.add(player)
    9696
Note: See TracChangeset for help on using the changeset viewer.