Exemple #1
0
        typed = False
        hurt = Player_Effects(["rcs/imgs/player/hurt.png"], [0,0], screenSize, 10)

        map = Level("map1", screenSize)

        boss = Boss(['rcs/imgs/bosses/boss.png'], [0,0], screenSize, 10)
        boss.place([300,500])
        sword = Sword(screenSize)
        counter = Counter([45,25], screenSize) 

        healthbar_imgs = []
        for i in range(100, 0, -5):
            healthbar_imgs += ["rcs/imgs/stats_bar/health_bar_" + str(i) + "%.png"]
            
        healthbar = Screen(healthbar_imgs, [0, 0], screenSize)
        healthbar.place([645,13])
        energybar_background = Screen(["rcs/imgs/stats_bar/energy_bar_background.png"], [0,0], screenSize)
        energybar_background.place([640, 25])
        energybar_imgs = ["rcs/imgs/stats_bar/nothing.png"]

        for i in range(5, 105, 5):
            energybar_imgs += ["rcs/imgs/stats_bar/energy_bar_" + str(i) + "%.png"]
            
        energybar = Screen(energybar_imgs, [0, 0], screenSize)
        energybar.place([645,28])
        healthbar_background = Screen(["rcs/imgs/stats_bar/healthbar_background.png"], [0,0], screenSize)
        healthbar_background.place([640, 10])

        if pygame.mixer:
            song = pygame.mixer.music.load('rcs/sounds/soundtracks/RPG_Soundtrack.ogg')
        if pygame.mixer: