added variable speed bullets (type2)

This commit is contained in:
kleph 2010-02-22 23:38:44 +01:00
parent c283049246
commit 85982e9fca

View file

@ -101,6 +101,15 @@ class BulletFactory():
bullet.damage = 10
return bullet
def create_type2(self, pos, speed):
""" create a bullet of type 2
temporary ennemies bullet """
bullet = Bullet(['bullet.bmp'], 0, pos)
bullet.speed = speed
bullet.damage = 10
return bullet
class Bullet(Object):
def __init__(self, frames, type, pos):
Object.__init__(self, frames, pos, (0, 0))