Example #1
0
    def create_layer(self):

        layer = Square((255, 255, 255, 1), 0, 0, 640)
        hero = Hero()
        print(hero.sprite)
        if hero.sprite is not None:
            hero.change_to("R")
        else:
            hero.change_to("A")
        layer.add(hero.sprite)
        ctrl = WarCtrl(hero)
        self.add(layer)
        self.add(ctrl)