Created
February 3, 2017 15:06
-
-
Save codetravis/7c0d710d39883706a29e4c0d0a434c9b to your computer and use it in GitHub Desktop.
13.5 Add Boss image from sprite sheet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
' Give the boss an image from the sprite sheet | |
Method CreateFinalBoss() | |
Local box:ftObject = Self.engine.CreateImage(game_sprite_atlas.GetImage("tutorial_boss"), engine.GetCanvasWidth() - 10, engine.GetCanvasHeight()/2) | |
box.SetColor(255, 0, 255) | |
box.SetMaxSpeed(20.0) | |
box.SetMinSpeed(-20.0) | |
box.SetColGroup(ENEMY_GROUP) | |
box.SetColWith(PLAYER_GROUP, True) | |
box.SetText("FINALBOSS") | |
Local projectile_type:ProjectileType = New ProjectileType(1, 1000, 0.2, 25, 1.5) | |
Self.final_boss = New Character(box, projectile_type, 500, 10, "FINALBOSS") | |
End |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment