Extensive work on virtually all of the visuals and the net code

This commit is contained in:
2026-03-01 21:26:31 -05:00
parent e7570c78c3
commit bed068eafc
180 changed files with 46533 additions and 913 deletions

View File

@@ -1,4 +1,4 @@
class_name PawnInput extends Node
class_name PawnInput extends MultiplayerSynchronizer
@export var dir : Vector3
@@ -8,31 +8,33 @@ class_name PawnInput extends Node
func _ready() -> void:
pressed = {
"left cycle trap":false,
"right cycle trap":false,
"left cycle hack":false,
"right cycle hack":false,
"detonate":false,
"detect":false,
"lay trap":false,
"install":false,
"attack":false
}
just_pressed = {
"left cycle trap":false,
"right cycle trap":false,
"left cycle hack":false,
"right cycle hack":false,
"detonate":false,
"detect":false,
"lay trap":false,
"install":false,
"attack":false
}
just_released = {
"left cycle trap":false,
"right cycle trap":false,
"left cycle hack":false,
"right cycle hack":false,
"detonate":false,
"detect":false,
"lay trap":false,
"install":false,
"attack":false
}
func _physics_process(delta: float) -> void:
if get_multiplayer_authority() != Multiplayer.id:
return
var d = Input.get_vector("west", "east", "north", "south")
dir = Vector3(d.x, 0, d.y)
for key : String in pressed:
@@ -45,6 +47,8 @@ func _physics_process(delta: float) -> void:
just_pressed[key] = false
pressed[key] = false
func is_action_pressed(action : String) -> bool:
return pressed.has(action) && pressed[action]