view pytouhou/game/player.pxd @ 455:6864a38b2413

Make pytouhou.lib.sdl cimportable, and convert pytouhou.ui.window.* to extension types.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Mon, 02 Sep 2013 22:16:38 +0200
parents 78e1c3864e73
children 4ccc47828002
line wrap: on
line source

from pytouhou.game.element cimport Element
from pytouhou.game.game cimport Game

cdef class PlayerState:
    cdef public double x, y
    cdef public bint touchable, focused
    cdef public long character, score, effective_score, lives, bombs, power, graze, points, invulnerable_time, power_bonus


cdef class Player(Element):
    cdef public PlayerState state
    cdef public long death_time
    cdef public Game _game

    cdef object anm
    cdef tuple speeds
    cdef long fire_time, direction

    cdef void set_anim(self, index)
    cpdef play_sound(self, str name)
    cpdef collide(self)
    cdef void fire(self)
    cpdef update(self, long keystate)