# # Flame.py # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; version 2 of the License. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # Copyright # Author: Nicholas F. Hoover # Contributors: # Created: 2007.07.04 # Last Modified: 2007.07.24 # from GameObject import TimedGameObject from Animation import Animation class Flame(TimedGameObject): ############## # ANIMATIONS # ############## NUM_ANIMATIONS = 1 FLAME = 0 LEFT = NUM_ANIMATIONS ############### # FRAME TICKS # ############### FLAME_FRAME_TICKS = 3 ############## # KEY FRAMES # ############## FLAME_KEY_FRAME = Animation.ALL_KEY_FRAMES ################### # ANIMATION TABLE # ################### ANIMATION_TABLE = [(FLAME, 'Flame', FLAME_FRAME_TICKS, FLAME_KEY_FRAME, True)] DEFAULT_ANIMATION = FLAME ######## # MISC # ######## RECT_SIZE = (50,50) TICKS_TO_LIVE = 20 class Gas(TimedGameObject): ############## # ANIMATIONS # ############## NUM_ANIMATIONS = 1 GAS = 0 LEFT = NUM_ANIMATIONS ############### # FRAME TICKS # ############### GAS_FRAME_TICKS = 3 ############## # KEY FRAMES # ############## GAS_KEY_FRAME = Animation.ALL_KEY_FRAMES ################### # ANIMATION TABLE # ################### ANIMATION_TABLE = [(GAS, 'Gas', GAS_FRAME_TICKS, GAS_KEY_FRAME)] DEFAULT_ANIMATION = GAS ######## # MISC # ######## RECT_SIZE = (60,25) TICKS_TO_LIVE = 15