Wired up boss heart behaviour
This commit is contained in:
parent
bee8cf77f1
commit
a13f274767
7 changed files with 95 additions and 15 deletions
|
|
@ -7,7 +7,7 @@ var start_pos = Vector2.ZERO
|
|||
var speed = 0
|
||||
var tween_speed: float = 1.4
|
||||
|
||||
var horse_counter = 0
|
||||
var horse_counter = 1
|
||||
|
||||
var exploding = false
|
||||
|
||||
|
|
@ -39,8 +39,9 @@ func boss_horse():
|
|||
print("Boss horse!")
|
||||
await get_tree().create_timer(2).timeout
|
||||
EventBus.flash_screen.emit(.25)
|
||||
$Sprite2D.frame = 7
|
||||
$Heart.hide()
|
||||
$Horse.show()
|
||||
$Sprite2D.frame = 7
|
||||
$Horse.start()
|
||||
var horse_player = $Horse/AnimationPlayer
|
||||
horse_player.play("run")
|
||||
|
|
@ -48,23 +49,38 @@ func boss_horse():
|
|||
EventBus.flash_screen.emit(.25)
|
||||
$Horse.hide()
|
||||
$Horse.end()
|
||||
horse_counter += 1
|
||||
await get_tree().create_timer(5).timeout
|
||||
horse_counter += 1
|
||||
lady_of_whispers()
|
||||
|
||||
|
||||
func lady_of_whispers():
|
||||
print("Lady of Whispers!")
|
||||
boss.play("rise")
|
||||
await get_tree().create_timer(4).timeout
|
||||
boss.play("whisper")
|
||||
await get_tree().create_timer(1).timeout
|
||||
boss_horse()
|
||||
|
||||
if horse_counter == 2:
|
||||
|
||||
print("Lady of Whispers offers you a heart!")
|
||||
boss.play("rise")
|
||||
await get_tree().create_timer(4).timeout
|
||||
# boss.play("whisper")
|
||||
offer_heart()
|
||||
|
||||
if horse_counter <= 1:
|
||||
print("Lady of Whispers!")
|
||||
boss.play("rise")
|
||||
await get_tree().create_timer(4).timeout
|
||||
boss.play("whisper")
|
||||
await get_tree().create_timer(1).timeout
|
||||
boss_horse()
|
||||
|
||||
func hit_detection():
|
||||
return
|
||||
|
||||
|
||||
func offer_heart():
|
||||
$Heart.show()
|
||||
await get_tree().create_timer(4).timeout
|
||||
boss_horse()
|
||||
horse_counter = 0
|
||||
print("Horse Counter:",horse_counter)
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue