Changeset 395:135cbb99511f


Ignore:
Timestamp:
04/09/11 14:41:44 (12 years ago)
Author:
Jeremy Thurgood <firxen@…>
Branch:
default
Phase:
public
Message:

Hook up fan.

Location:
skaapsteker/sprites
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • skaapsteker/sprites/items.py

    r388 r395  
    102102
    103103
     104    def player_action(self, player):
     105        player.get_fan(self)
     106
     107
    104108
    105109##################################################
  • skaapsteker/sprites/player.py

    r391 r395  
    99from ..constants import Layers, FoxHud, DOUBLE_TAP_TIME, RECHARGE_TIME
    1010from ..data import get_files, load_image
    11 from ..engine import PlayerDied, AddSpriteEvent
     11from ..engine import PlayerDied, AddSpriteEvent, OpenNotification
    1212
    1313
     
    476476        self._me.scrolls.append(scroll.text)
    477477
     478
     479    def get_fan(self, fan):
     480        if self.shape == 'fox':
     481            OpenNotification.post("A fox cannot use a fan.")
     482            return
     483        fan.remove()
     484        self._me.has_fan = True
     485        self.shape = 'human_with_fan'
     486        self.set_image()
     487
Note: See TracChangeset for help on using the changeset viewer.