mirror of
https://github.com/Steffo99/pineapple-surf.git
synced 2024-11-25 17:24:19 +00:00
12 lines
269 B
GDScript
12 lines
269 B
GDScript
extends Node
|
|
|
|
|
|
@onready var player: Node3D = $".."
|
|
@onready var spawn_point: Vector3 = player.position
|
|
@onready var splash_sound: AudioStreamPlayer = $SplashSound
|
|
|
|
|
|
func _process(_delta):
|
|
if player.position.y < 0:
|
|
splash_sound.play()
|
|
player.position = spawn_point
|