New Icon; Touch Controls; Menu with Help; Added Music
This commit is contained in:
parent
9e3349eec3
commit
e87f8c3756
71 changed files with 1084 additions and 278 deletions
46
scenes/game/entities/player/touch_controlls.gd
Normal file
46
scenes/game/entities/player/touch_controlls.gd
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
extends Control
|
||||
|
||||
func _ready() -> void:
|
||||
if DisplayServer.is_touchscreen_available():
|
||||
show()
|
||||
|
||||
|
||||
|
||||
func _on_up_button_button_down() -> void:
|
||||
Input.action_press("MOVE_UP")
|
||||
|
||||
func _on_up_button_button_up() -> void:
|
||||
Input.action_release("MOVE_UP")
|
||||
|
||||
|
||||
|
||||
|
||||
func _on_left_button_button_down() -> void:
|
||||
Input.action_press("MOVE_LEFT")
|
||||
func _on_left_button_button_up() -> void:
|
||||
Input.action_release("MOVE_LEFT")
|
||||
|
||||
|
||||
func _on_down_button_button_down() -> void:
|
||||
Input.action_press("MOVE_DOWN")
|
||||
func _on_down_button_button_up() -> void:
|
||||
Input.action_release("MOVE_DOWN")
|
||||
|
||||
|
||||
func _on_right_button_button_down() -> void:
|
||||
Input.action_press("MOVE_RIGHT")
|
||||
func _on_right_button_button_up() -> void:
|
||||
Input.action_release("MOVE_RIGHT")
|
||||
|
||||
|
||||
func _on_roll_button_button_down() -> void:
|
||||
Input.action_press("ROLL")
|
||||
func _on_roll_button_button_up() -> void:
|
||||
Input.action_release("ROLL")
|
||||
|
||||
|
||||
|
||||
func _on_pickup_button_button_down() -> void:
|
||||
Input.action_press("Pickup")
|
||||
func _on_pickup_button_button_up() -> void:
|
||||
Input.action_release("Pickup")
|
||||
Loading…
Add table
Add a link
Reference in a new issue