it just werks

This commit is contained in:
pennyrigate 2025-03-02 18:02:05 -05:00
parent 1311e18f1f
commit 7e26433676
50 changed files with 1181 additions and 11 deletions

View file

@ -10,6 +10,9 @@ extends CharacterBody2D
@export var state_chart: StateChart
@export var graphics: Node2D
@onready var start_position = position
@onready var voice = %Voice
var ices_touched:int = 0:
set(value):
ices_touched = value
@ -23,7 +26,6 @@ var ices_touched:int = 0:
func _ready() -> void:
state_chart.set_expression_property(&"player", self)
func _unhandled_input(event: InputEvent) -> void:
if event.is_action_pressed(&"ui_accept"):
state_chart.send_event(&"jump_pressed")
@ -59,6 +61,8 @@ func _process_gravity(delta: float) -> void:
#region State One-Shots
func _do_jump() -> void:
voice.stream = load("res://assets/audio/vox/capri_jump.ogg")
voice.play()
velocity.y = -jump_force
position.y -= 1.0