Ejemplo n.º 1
0
 def __init__(self):
     Entity.__init__(self)
     
     self.collide_walls = True
     
     self.walk_speed = 100
     self._movement_vectors = []
     self._walking = {
         Character.Direction.UP : False, 
         Character.Direction.RIGHT : False, 
         Character.Direction.DOWN : False, 
         Character.Direction.LEFT : False
             }        
     
     self.max_hitpoints = self.current_hitpoints = 10
     self.hitbar_health_color = 0, 255, 0
     self.hitbar_damage_color = 255, 0, 0
     
     self.sprites = {
         Character.Direction.UP : 0, 
         Character.Direction.RIGHT : 0, 
         Character.Direction.DOWN : 0, 
         Character.Direction.LEFT : 0
             }
     self.facing = Character.Direction.DOWN
Ejemplo n.º 2
0
 def __init__(self,
     number:int=0,
     name:str='<Default Company Name>',
     address:list=list(['<Default Address, line %u>' %(n+1) for n in range(4)]),
     btwNumber:str='', # => don't show BTW number on factuur, do charge BTW
     reference:str='',
     paymentTerms:list=[
              "Betaling naar bankrekening (zie gegevens boven) binnen 30 dagen wordt op prijs gesteld.",
              "Bij betaling svp factuurnummer vermelden.",
     ],
     restitutionTerms:list=[
          "Het positieve van de hierbovengenoemde negatieve totaal wordt vandaag overgeboekt ",
          "volgens uw instructies.",
     ],
     companyLogo:str='',
     cars:list=[],
 ):
     Entity.__init__(self,
         number=number,
         name=name,
         address=address,
         btwNumber=btwNumber,
         reference=reference,
         paymentTerms=paymentTerms,
         restitutionTerms=restitutionTerms,
         companyLogo=companyLogo,
         cars=cars,
     )
Ejemplo n.º 3
0
 def __init__(self, level, cord, color):
     self.cord = cord
     self.space = level.tileSpace
     self.level = level
     self.color = color
     Entity.__init__(self, None)
     self.stone = None
Ejemplo n.º 4
0
    def __init__(self,
                 pos=[0, 0],
                 vel=[0, 0],
                 group=None,
                 width=0,
                 height=0,
                 **kwargs):
        img = pygame.Surface((width, height)).convert()
        Entity.__init__(self,
                        pos, [0, 0],
                        img,
                        group,
                        pygame.Rect(0, 0, width, height),
                        animated=False,
                        **kwargs)
        self.visible = 0
        if PureSensor.instanceSpecificVars is None:
            attrList = list(self.__dict__.keys())

        self.w, self.h = width, height
        if PureSensor.instanceSpecificVars is None:
            PureSensor.instanceSpecificVars = dict([
                (eachKey, eachVal)
                for eachKey, eachVal in self.__dict__.items()
                if eachKey not in attrList
            ])
Ejemplo n.º 5
0
 def __init__(self, player):
     Entity.__init__(self, player.level, player.y, player.x)
     self.player = player
     self.num_ticks = NUM_TICKS
     self.curr_tick = NUM_TICKS
     self.radius = 3
     self.created_at = time.time()
Ejemplo n.º 6
0
 def __init__(self, level):
     Entity.__init__(self)
     self._category = '_Environment'
     self._level = level
     self.animPath = ''
     self.graphics = ''
     self.physics = ''
Ejemplo n.º 7
0
 def __init__(self):
     Entity.__init__(self)
 
     self.slash_duration = 64
     self.damage_output = 1
     self._force = 640 #TODO: This is just a placeholder value.
 
     self.setVisible(False)
 
     #TODO: Put sprites into a spritesheet
     self.hold_sprites = {}
     self.hold_sprites[Character.Direction.UP] = loadImage('knifeb.bmp')
     self.hold_sprites[Character.Direction.RIGHT] = loadImage('knifer.bmp')
     self.hold_sprites[Character.Direction.DOWN] = loadImage('knifef.bmp')
     self.hold_sprites[Character.Direction.LEFT] = loadImage('knifel.bmp')
 
     #TODO: For dual-handed whatevers, these shouldn't be keyed to character directions after all. (If I ever do that.) 
     self.swing_sprites = {}
     self.swing_sprites[Character.Direction.UP] = loadImage('knifeslashne.bmp')
     self.swing_sprites[Character.Direction.RIGHT] = loadImage('knifeslashse.bmp')
     self.swing_sprites[Character.Direction.DOWN] = loadImage('knifeslashsw.bmp')
     self.swing_sprites[Character.Direction.LEFT] = loadImage('knifeslashnw.bmp')
 
     self.sprites = self.hold_sprites #Change self.sprites to the appropriate set...?
 
     self.facing = Character.Direction.DOWN
     self.attacker = None        
     self.attacking = False
     self.is_slash = False
     
     self._atk_origin = [0, 0]
     self.slash_timer = Timer(self.slash_duration, self.finishSlash)
     self.slash_timer.pause()
Ejemplo n.º 8
0
 def __init__(self, level):
     Entity.__init__(self)
     self._category = '_Environment'
     self._level = level
     self.animPath = ''
     self.graphics = ''
     self.physics = ''
Ejemplo n.º 9
0
 def __init__(self, player):
     Entity.__init__(self, player.level, player.y, player.x)
     self.player = player
     self.num_ticks = NUM_TICKS
     self.curr_tick = NUM_TICKS
     self.radius = 3
     self.created_at = time.time()
Ejemplo n.º 10
0
 def __init__(self, level):
     Entity.__init__(self)
     self.level = level
     self.enemy_type = random.randint(0, self.num_enemy_types)
     self.init_stats()
     for i in range(0, level):
         self.give_rand_adj()
Ejemplo n.º 11
0
    def __init__(
            self,
            max_speed=1.0,
            average_turn=20.0,
            turn_std_dev=5.0,
            probability_positive_turn=0.5,
            x_pos=0.0,
            y_pos=0.0,
            parent=None):

        Entity.__init__(self, x_pos=x_pos, y_pos=y_pos, parent=parent)

        # basic attributes
        self.direction = 0.0
        self.max_speed = max_speed
        self.average_turn = average_turn
        self.turn_std_dev = turn_std_dev
        self.positive_turn = probability_positive_turn

        self.curr_x = x_pos
        self.curr_y = y_pos

        # Memory of movement
        self.X = []  # x position
        self.Y = []  # y position
        self.A = []  # angle turned
        self.X.append(self.curr_x)
        self.Y.append(self.curr_y)
        self.A.append(0.0)
Ejemplo n.º 12
0
    def __init__(self, ip, uid, x=200, y=200):

        Entity.__init__(self, x, y, (40, 60), "player", uid)
        self.ip = ip

        # LEFT RIGHT UP DOWN ATTACK INTERACT
        self.buttons = {
            "jump": False,
            "left": False,
            "down": False,
            "right": False,
            "attack": False,
            "interact": False
        }

        self.held = {
            "jump": False,
            "left": False,
            "down": False,
            "right": False,
            "attack": False,
            "interact": False
        }

        self.facing = "right"
        self._movementModifier = 10
        self._jumpModifier = 30
        self.shot = False  # just shot a bullet - TODO
        self.sprite = "stillUnarmed"
Ejemplo n.º 13
0
    def __init__(self, name, **properties):
        self._account = None

        Entity.__init__(self, 'category', name, **properties)

        # Category id is it's name
        self._id = name
Ejemplo n.º 14
0
    def __init__(self,
        text="<no text specified>",
        width=None,
        height=None,
        collision=Entity.BLOCK,
        draworder=10,
        rsize=None,
        halo_img="default",
        width_ofs=0,
        height_ofs=0,
        double=False,
        permute=True,
        dropshadow=False,
        dropshadow_color=sf.Color(30,30,30,150),
        colored_halo=True):

        self.colored_halo = colored_halo
        
        # Note: the 'constants' from defaults may change during startup, but 
        # this file may get parsed BEFORE this happens, so we can't
        # access defaults safely from default arguments which are 
        # stored at parse-time.
        height = height or Tile.AUTO
        width  = width  or Tile.AUTO
        rsize  = rsize  or defaults.letter_size[1]
        scale  =  rsize / defaults.letter_size[1] 
        
        self.permute = permute
            
        Entity.__init__(self)

        self.scale = scale
        self.rsize = rsize
        self.collision = collision
        self.text = text
        self.double = double
        self.dropshadow = dropshadow
        self.dropshadow_color = dropshadow_color

        self.optimized_text_elem = None
            
        self.draworder = draworder
        self.halo_img = halo_img
        
        # if either width and height are AUTO, compute the minimum bounding
        # rectangle for all glyph bounding rectangles.
        if width==Tile.AUTO or height==Tile.AUTO:
            self.dim,self.ofs = self._GuessRealBB(self.text)
            
        elif width==Tile.AUTO_QUICK or height==Tile.AUTO_QUICK:
            self.dim,self.ofs = self._GuessRealBB_Quick(self.text)
            
        else:
            self.dim = self._LetterToTileCoords(width,height)
            self.ofs = (width_ofs,height_ofs)
            
        
        if self.permute:
            self.text = self._Permute(self.text)
        self._Recache()
Ejemplo n.º 15
0
 def __init__(self, country_id: int, year: int, life_expectancy: float, population: int, gdp_per_capita: float):
     Entity.__init__(self)
     self.country_id = country_id
     self.year = year
     self.life_expectancy = life_expectancy
     self.population = population
     self.gdp_per_capita = gdp_per_capita
Ejemplo n.º 16
0
    def __init__(self, position):
        Entity.__init__(self)
        # Physics stuff
        self.position = position
        self.velocity = Vector2(0, 0)
        self.acceleration = Vector2(0, 0)

        # Image stuff
        self.animations = {}
        self.currentAnimation = None
        self.flipHorizontal = False
        self.offset = Vector2(0, 0)
        self.visible = True

        # z
        self.z = 0
        self.zVelocity = 0

        # self.shadow = content.images["shadow.png"]
        self.shadowSize = 14
        self.shadowOffset = Vector2(0, 0)
        self.shadowVisible = True

        # layering
        self.layerIndex = 0

        # rotation
        self.angle = 0
Ejemplo n.º 17
0
    def __init__(self, ent, anim=None):
        self.flagName = ent.name
        Entity.__init__(self, ent, anim)
        self.invincible = True

        if self.flagName in savedata.__dict__:
            self.remove()
Ejemplo n.º 18
0
 def __init__(
     self,
     number: int = 0,
     name: str = '<Default Company Name>',
     address: list = list(
         ['<Default Address, line %u>' % (n + 1) for n in range(4)]),
     btwNumber:
     str = '',  # => don't show BTW number on factuur, do charge BTW
     reference: str = '',
     paymentTerms: list = [
         "Betaling naar bankrekening (zie gegevens boven) binnen 30 dagen wordt op prijs gesteld.",
         "Bij betaling svp factuurnummer vermelden.",
     ],
     restitutionTerms: list = [
         "Het positieve van de hierbovengenoemde negatieve totaal wordt vandaag overgeboekt ",
         "volgens uw instructies.",
     ],
     companyLogo: str = '',
     cars: list = [],
 ):
     Entity.__init__(
         self,
         number=number,
         name=name,
         address=address,
         btwNumber=btwNumber,
         reference=reference,
         paymentTerms=paymentTerms,
         restitutionTerms=restitutionTerms,
         companyLogo=companyLogo,
         cars=cars,
     )
Ejemplo n.º 19
0
 def __init__(self, engine, color, axis_get_func):
     Entity.__init__(self, engine)
     self.color = color
     self.get_axis = axis_get_func
     self.pos = pos(0, 0) 
     self.velocity = pos(0, 0)
     self._speed = 1.0
Ejemplo n.º 20
0
	def __init__(self, x, y, level, color = None):
		Entity.__init__(self)
		self.image = Surface((16, 16))
		if color: self.image.fill(color)
		self.image.convert()
		self.rect = Rect(x, y, 16, 16)
		self.level = level
Ejemplo n.º 21
0
    def __init__(self, id: int, quest: Quest) -> None:
        Entity.__init__(self, quest)
        FromDB.__init__(self, id)
        if self._data is None:
            self.hp.set_base_max(self._data["_HP"])

        self.quest.set_enemy(self)
Ejemplo n.º 22
0
	def __init__(self, board):
		size = 15
		x = board.getWidth()/2 - size/2
		y = board.getHeight()/2 - size/2
		Entity.__init__(self, x, y, size)
		self.speed = 100
		self.dead = False
Ejemplo n.º 23
0
 def __init__(self, position, mailbox, user, direction):
     self.user = user
     Entity.__init__(self, position, mailbox)
     self.direction = direction
     self.entities_to_kill = set()
     # Start detonation
     self.state_interval = self.STATE_INTERVAL
Ejemplo n.º 24
0
    def __init__(self, Surface, pos = (0,0), direction = (0,0),
                 speed = (0,0), friction = 0.2, damage = 10,
                 density = 0.91, shooter = None):

        self.damage = damage
        self.shooter = shooter
        Entity.__init__(self, Surface, pos = pos, direction = direction,
                        speed = speed, density = density, friction = 0.2)
Ejemplo n.º 25
0
Archivo: task.py Proyecto: giann/clerk
    def __init__(self, name, **properties):
        self._due = None
        self._recurrence = None
        self._priority = "low"
        self._memo = None
        self._completed = None

        Entity.__init__(self, "task", name, **properties)
Ejemplo n.º 26
0
 def __init__(self, group, pos=[0, 0], vel=[0, 0]):
     Entity.__init__(self,
                     pos,
                     vel,
                     image=None,
                     group=group,
                     rect=None,
                     animated=None)
Ejemplo n.º 27
0
 def __init__(self, x, y, image, folder=''):
     pygame.sprite.Sprite.__init__(self)
     self.image, self.rect = load_image(image,
                                        colorkey=(255, 255, 255),
                                        folder=folder)
     Entity.__init__(self, x, y, self.rect.w, self.rect.h)
     self.rect.left = x
     self.rect.top = y
Ejemplo n.º 28
0
    def __init__(self, pos_x, pos_y, angle_rad, surface, dt):

        Entity.__init__(self, pos_x, pos_y, surface, dt, self.VERTICES)
        self.speed = 500.0
        self.angle = angle_rad
        self.time = 0.0
        self.velocity[0] = self.speed * math.cos(self.angle)
        self.velocity[1] = self.speed * math.sin(self.angle)
Ejemplo n.º 29
0
 def __init__(self, entity_id, pos_y, pos_x, symbol, aggressive, name, range_of_vision, hp, minimum_damage, maximum_damage, effects, accuracy):
     Entity.__init__(self, entity_id, pos_y, pos_x, symbol, range_of_vision, hp, minimum_damage, maximum_damage, effects, accuracy)
     self.name = name
     self.aggressive = aggressive
     self.hit_by_player = False
     self.visible = []
     self.drugged_pos_y = -1
     self.drugged_pos_x = -1
Ejemplo n.º 30
0
 def __init__(self, ent):
     Entity.__init__(self, ent, self._anim)
     self.anim = 'default'
     self.invincible = True
     self.state = self.boomState()
     self.duration = 42
     self.timer = 0
     sound.explode.Play()
Ejemplo n.º 31
0
 def __init__(self, x, y):
     Entity.__init__(self)
     self.xvel = x
     self.yvel = y
     self.onGround = False
     self.image = image.load(img_heror)
     (hauteur, largeur) = self.image.get_size()
     self.rect = Rect(x, y, hauteur, largeur)
Ejemplo n.º 32
0
    def __init__(
            self,
            length=100,
            width=100,
            n_patches=0):

        Entity.__init__(self, length=length, width=width)
        self.create_patches(n_patches)
Ejemplo n.º 33
0
    def __init__(self, game: 'Game'):

        Entity.__init__(self, game, 'Unnamed Inventory')

        self.game: 'Game' = game

        # a dict of inventory items and stack amount
        self.inventory = {}
Ejemplo n.º 34
0
    def __init__( self, pos=[0,0], vel=[0,0], group=None, **kwargs ):
        Entity.__init__( self, pos, [0,0], None, group, pygame.Rect( 0, 0, self.width, self.height ), animated=False, **kwargs )
        self.visible = 0
        if EmptyPoint.instanceSpecificVars is None:
            attrList = list( self.__dict__.keys() )

        if EmptyPoint.instanceSpecificVars is None:
            EmptyPoint.instanceSpecificVars = dict( [ ( eachKey, eachVal ) for eachKey, eachVal in self.__dict__.items() if eachKey not in attrList ] )
Ejemplo n.º 35
0
 def __init__(self, pos_x, pos_y, surface, dt):
     Entity.__init__(self, pos_x, pos_y, surface, dt, self.VERTICES)
     
     self.angle = random.uniform(0.0, 360.0)
     self.spin = random.uniform(-1.0, 1.0)
     self.speed = 50.0
     #self.scale = Vector(5, 5)
     self.velocity = Vector(self.speed * random.uniform(-1.0, 1.0), self.speed * random.uniform(-1.0, 1.0))
Ejemplo n.º 36
0
 def __init__(self, x, y):
     Entity.__init__(self, x, y)
     self.img = image.load(path.join('sprites', ENITY_SPRITES[0]))
     self.ref_img = self.img
     self.offsetWidth = int(0.5 * (self.img.get_width()))
     self.offsetHeight = int(0.5 * (self.img.get_height()))
     self.centreX = int(0.5 * (self.img.get_width())) + x
     self.centreY = int(0.5 * (self.img.get_height())) + y
Ejemplo n.º 37
0
    def __init__(self, pos_x, pos_y, surface, dt):
        Entity.__init__(self, pos_x, pos_y, surface, dt, self.VERTICES)

        self.angle = random.uniform(0.0, 360.0)
        self.spin = random.uniform(-1.0, 1.0)
        self.speed = 50.0
        # self.scale = Vector(5, 5)
        self.velocity = Vector(self.speed * random.uniform(-1.0, 1.0), self.speed * random.uniform(-1.0, 1.0))
Ejemplo n.º 38
0
Archivo: hero.py Proyecto: renton/0g
    def __init__(self):
        Entity.__init__(self, 200, 200, 40, 40, 0, 0)

        self.debug_color = (23,33,220)
        self.is_sticky = True
        self.speed = 6
        self.boost_multiplier = 2
        self.boost_ready = False
Ejemplo n.º 39
0
 def __init__(self, x, y, col):
     # Numero du niveau #
     num = sys.argv[1]
     lvlPf = generateTypePlateform(num)
     Entity.__init__(self)
     name = "graphics/decor/"+lvlPf+"/"+ col +".png"
     self.image = image.load(name)
     self.rect = Rect(x, y, 32, 32)
Ejemplo n.º 40
0
 def __init__(self, x=0, y=0, f=Action.South):
     Entity.__init__(x, y, f)
     self.nextAction = Action.Wait
     
     # store player statistics
     self.moves = 0
     
     if debug.active: print self
Ejemplo n.º 41
0
 def __init__(self, x, y):
     Entity.__init__(self)
     self.xvel = x
     self.yvel = y
     self.onGround = False
     self.image = pygame.image.load(self.img_bossf)
     (hauteur, largeur) = self.image.get_size()
     self.rect = Rect(x, y, hauteur, largeur)
Ejemplo n.º 42
0
	def __init__(self, world):
		Entity.__init__(self, world)
		self.singular = 'a priest'

		self.ai.addAI(task.Fallback(self))
		self.ai.addAI(task.Cast(self))
		self.ai.addAI(task.Follow(self))
		self.ai.addAI(task.Wander(self))
Ejemplo n.º 43
0
 def __init__(self, isEnnemy):
     Entity.__init__(self)
     self.isEnnemy = TimestampedValue('i', isEnnemy)
     self.champion = TimestampedValue('i', CHAMPION.UNKNOWN)
     self.skills = [Skill() for j in range(4)]
     self.range = TimestampedValue('i', -1) # 0 for melee champion ?
     self.mana = TimestampedValue('i', -1)
     self.speed = TimestampedValue('i', -1)
Ejemplo n.º 44
0
 def __init__(self, fish_image_path, viewable_min_r, viewable_max_r):
     Entity.__init__(self)
     self.fish_image_path = fish_image_path
     self.regenerate(viewable_min_r, viewable_max_r)
     self.fish_direction = LEFT_TO_RIGHT
     self.fish_num = 1
     self.fish_image_filename = ""
     self.y = 0
Ejemplo n.º 45
0
 def __init__(self,
              filename,
              lineno,
              identifier,
              function):
     Entity.__init__(self, filename, lineno)
     ResolutionSymbols.__init__(self)
     self.identifier = identifier
     self.function = function
Ejemplo n.º 46
0
 def __init__(self, x, y, size, uid, sprite=None):
     Entity.__init__(self,
                     x,
                     y,
                     size,
                     "platform",
                     uid,
                     gravity=False,
                     sprite=None)
Ejemplo n.º 47
0
 def __init__(self, pos_x, pos_y, angle_rad, surface, dt):
     
     
     Entity.__init__(self, pos_x, pos_y, surface, dt, self.VERTICES)
     self.speed = 500.0
     self.angle = angle_rad
     self.time = 0.0
     self.velocity[0] = self.speed * math.cos(self.angle)
     self.velocity[1] = self.speed * math.sin(self.angle)
Ejemplo n.º 48
0
 def __init__(self, x, y):
     Entity.__init__(self)
     Stats.__init__(self, "graphics/character/boss/boss1/boss1r.png", 3, 8)
     self.xvel = x
     self.yvel = y
     self.onGround = False
     self.image = pygame.image.load(self.img_bossf)
     (hauteur, largeur) = self.image.get_size()
     self.rect = Rect(x, y, hauteur, largeur)
Ejemplo n.º 49
0
 def __init__(self, x, y, velocity, uid):
     Entity.__init__(self,
                     x,
                     y, (8, 4),
                     "bullet",
                     uid,
                     gravity=False,
                     velocity=velocity,
                     destroyOnWall=True)
Ejemplo n.º 50
0
	def __init__(self, line=0, *args, **kwargs):
		self.sprites = deepcopy(alien1)
		self.sprites_destroy = deepcopy(alien1_destroy)

		Entity.__init__(self, *args, **kwargs)

		self.line = line
		self.speed = 1
		self.point = 10
Ejemplo n.º 51
0
    def __init__(self, x, y, xml_data, driver, image=None):
        self.dmg = int(xml_data.get("dmg"))
        Entity.__init__(self, x, y, xml_data, driver, image=image)

        # Initialize the player as their target
        self.player = driver.player

        # Stun-time, how long they are stunned on hit
        self.stun_time = 0
Ejemplo n.º 52
0
 def __init__(self,
              filename,
              lineno,
              value = None,
              mappings = list()):
     Entity.__init__(self, filename, lineno)
     ResolutionSymbols.__init__(self)
     self.value = value
     self.mappings = mappings
Ejemplo n.º 53
0
    def __init__(self, x, y):
        global numbombs
        Entity.__init__(self, x, y, Sprite("bombs"), (6, 0, 20, 16))

        self.ticks = 45  # 30 ticks 'till kaboooom!

        numbombs += 1
        if numbombs > 3:
            self._destroy()
Ejemplo n.º 54
0
 def __init__(self):
     Entity.__init__(self)
     self.direction = 0
     self.previousDirection = 0
     self.facingDirection = 0
     self.speed = 60
     self.mover = FourWayMovement(self, version=3)
     self.velocity = Vector2D()
     self.overrideKeys = False
Ejemplo n.º 55
0
    def __init__(self, x, y):
        Entity.__init__(self)

        self.xvel = x+10
        self.yvel = y+10
        self.image = image.load(img_swordr)
        (hauteur, largeur) = self.image.get_size()
        self.rect = Rect(x, y, hauteur, largeur)
        self.onGround = False
Ejemplo n.º 56
0
    def __init__(self, pos_x, pos_y, surface, dt):
        Entity.__init__(self, pos_x, pos_y, surface, dt, self.VERTICES)
        self.alive = True
        self.angle = 180
        self.speed = 300

        #list of (angle,radius) pairs for the better looks
        #self.rel_points = [[0,20], [-140, 20],[180, 7.5],[140, 20]]
        self.scale = Vector(7, 7)
Ejemplo n.º 57
0
    def __init__(self, rect, name=''):
        Entity.__init__(self, rect.getPos())
        self.rect = rect
        self.name = name

        self.parent = None

        self.selected = False
        self.selectable = True
Ejemplo n.º 58
0
 def __init__(self, pos_x, pos_y, surface,dt):
     Entity.__init__(self, pos_x, pos_y, surface, dt, self.VERTICES)
     self.alive = True
     self.angle = 180
     self.speed = 300
     
     #list of (angle,radius) pairs for the better looks
     #self.rel_points = [[0,20], [-140, 20],[180, 7.5],[140, 20]]
     self.scale = Vector(7,7)
Ejemplo n.º 59
0
    def __init__(self, ent, anim=None):
        self.flagName = ent.name
        Entity.__init__(self, ent, anim)
        self.invincible = True
        #print self.flagName + ' inited'

        if self.flagName in savedata.__dict__:
            #print 'Removed ' + self.flagName
            self.remove()