mirror of
https://github.com/JHDev2006/Super-Mario-Bros.-Remastered-Public.git
synced 2025-10-22 07:28:14 +00:00
updated the pipe cutscene, so that itll use the pipewalk animation, and custom characters pipe sfx
This commit is contained in:
@@ -25,3 +25,6 @@ func update_next_level_info() -> void:
|
||||
func go_to_level() -> void:
|
||||
first_load = true
|
||||
Global.transition_to_scene(LevelTransition.level_to_transition_to)
|
||||
|
||||
func play_pipe_sfx() -> void:
|
||||
AudioManager.play_global_sfx("pipe")
|
||||
|
@@ -11,6 +11,7 @@ var character := ""
|
||||
func _ready() -> void:
|
||||
Global.player_characters_changed.connect(update)
|
||||
Global.level_theme_changed.connect(update)
|
||||
animation_changed.connect(on_animation_changed)
|
||||
update()
|
||||
|
||||
func update() -> void:
|
||||
@@ -30,3 +31,7 @@ func update() -> void:
|
||||
return
|
||||
if sprite_frames.get_frame_texture(animation, frame):
|
||||
offset.y = -(sprite_frames.get_frame_texture(animation, frame).get_height() / 2.0)
|
||||
|
||||
func on_animation_changed() -> void:
|
||||
if sprite_frames.has_animation(animation) == false and Player.ANIMATION_FALLBACKS.has(animation):
|
||||
play(Player.ANIMATION_FALLBACKS[animation])
|
||||
|
Reference in New Issue
Block a user