Renamed a bunch of player stuff to pawn stuff and implemented extensive work on getting single-address 'netplay' code working. Not sure if I've created issues with single player but in theory it should all transfer across as if the player is simply always the host.

This commit is contained in:
2026-01-08 07:15:20 -05:00
parent 9fe376e27e
commit ec02685065
69 changed files with 1525 additions and 708 deletions

View File

@@ -1,18 +1,14 @@
[gd_scene load_steps=9 format=3 uid="uid://by6suwmds7xq2"]
[gd_scene load_steps=6 format=3 uid="uid://by6suwmds7xq2"]
[ext_resource type="Script" uid="uid://d3t381vws7vns" path="res://scripts/test_level.gd" id="1_qcd3b"]
[ext_resource type="Script" uid="uid://d3t381vws7vns" path="res://scripts/level.gd" id="1_qcd3b"]
[ext_resource type="PackedScene" uid="uid://bgocskbofewsr" path="res://templates/HUD.tscn" id="1_x4b8f"]
[ext_resource type="Script" uid="uid://cymi1n4gavixy" path="res://scripts/level_camera.gd" id="3_qcd3b"]
[ext_resource type="Script" uid="uid://clqnjqolkujea" path="res://scripts/combat_target.gd" id="6_qcd3b"]
[ext_resource type="MeshLibrary" uid="uid://bhpyvhf36jl0f" path="res://testing.tres" id="7_88ety"]
[ext_resource type="MeshLibrary" uid="uid://cvhm40o2uw5mr" path="res://testing markers.tres" id="7_ahbqi"]
[sub_resource type="FastNoiseLite" id="FastNoiseLite_qcd3b"]
frequency = 0.02
fractal_octaves = 6
[sub_resource type="BoxShape3D" id="BoxShape3D_tmr53"]
size = Vector3(1, 2, 1)
[sub_resource type="Environment" id="Environment_x4b8f"]
ambient_light_color = Color(1, 1, 1, 1)
ambient_light_energy = 2.18
glow_enabled = true
[node name="Node3D" type="Node3D"]
script = ExtResource("1_qcd3b")
@@ -23,18 +19,6 @@ layer = 1000
[node name="HUD" parent="CanvasLayer" instance=ExtResource("1_x4b8f")]
[node name="Camera3D" type="Camera3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 0.49999997, 0.86602545, 0, -0.86602545, 0.49999997, 0, 18.855, 10.107289)
projection = 1
size = 5.0
script = ExtResource("3_qcd3b")
noise = SubResource("FastNoiseLite_qcd3b")
[node name="OmniLight3D" type="OmniLight3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 18.508709, 0)
omni_range = 25.142
omni_attenuation = -0.165
[node name="Floor" type="GridMap" parent="."]
unique_name_in_owner = true
mesh_library = ExtResource("7_88ety")
@@ -67,14 +51,26 @@ collision_layer = 0
collision_mask = 0
metadata/_editor_floor_ = Vector3(0, -1, 0)
[node name="Combat Target" type="StaticBody3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -5.926114, 0, -4.1967854)
script = ExtResource("6_qcd3b")
[node name="PawnSpawner" type="MultiplayerSpawner" parent="."]
_spawnable_scenes = PackedStringArray("uid://c8xf3qawk5c6u")
spawn_path = NodePath("../Pawns")
[node name="CSGBox3D" type="CSGBox3D" parent="Combat Target"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0)
size = Vector3(1, 2, 1)
[node name="TrapSpawner" type="MultiplayerSpawner" parent="."]
_spawnable_scenes = PackedStringArray("uid://bk3yqawritfnj")
spawn_path = NodePath("../Traps")
[node name="CollisionShape3D" type="CollisionShape3D" parent="Combat Target" groups=["combat"]]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0)
shape = SubResource("BoxShape3D_tmr53")
[node name="CameraSpawner" type="MultiplayerSpawner" parent="."]
_spawnable_scenes = PackedStringArray("uid://cqa0p34mbk6so")
spawn_path = NodePath("../Cameras")
[node name="Pawns" type="Node3D" parent="."]
unique_name_in_owner = true
[node name="Cameras" type="Node3D" parent="."]
unique_name_in_owner = true
[node name="Traps" type="Node3D" parent="."]
unique_name_in_owner = true
[node name="WorldEnvironment" type="WorldEnvironment" parent="."]
environment = SubResource("Environment_x4b8f")