made the first changes towards multiplayer working

This commit is contained in:
2023-11-13 19:36:35 +11:00
parent b0f8a37f60
commit f004f64b71
26 changed files with 305 additions and 257 deletions

View File

@ -55,12 +55,13 @@ viewport_path = NodePath("SubViewport")
[sub_resource type="ViewportTexture" id="ViewportTexture_574jy"]
viewport_path = NodePath("MiniMapViewport")
[node name="Character" type="CharacterBody3D" node_paths=PackedStringArray("camera", "left_hand", "right_hand", "right_hand_animator", "edit_tool", "gauntlet_sprite", "sprite", "interaction_raycast", "inventory", "card", "hud", "movement")]
[node name="Character" type="CharacterBody3D" node_paths=PackedStringArray("camera", "gun_camera", "left_hand", "right_hand", "right_hand_animator", "edit_tool", "gauntlet_sprite", "sprite", "interaction_raycast", "inventory", "card", "hud", "movement")]
collision_layer = 2
collision_mask = 37
script = ExtResource("1_pihpe")
hero_class = ExtResource("2_dbyo0")
camera = NodePath("Head")
gun_camera = NodePath("SubViewport/Head2")
left_hand = NodePath("SubViewport/Head2/LeftHand")
right_hand = NodePath("SubViewport/Head2/RightHand")
right_hand_animator = NodePath("SubViewport/Head2/RightHand/AnimationPlayer")
@ -169,6 +170,114 @@ hover_text = NodePath("Label2")
enemy_sprites = [NodePath("TextureRect4/TextureRect"), NodePath("TextureRect4/TextureRect2"), NodePath("TextureRect4/TextureRect3"), NodePath("TextureRect4/TextureRect4"), NodePath("TextureRect4/TextureRect5")]
enemy_counts = [NodePath("TextureRect4/TextureRect/Label"), NodePath("TextureRect4/TextureRect2/Label2"), NodePath("TextureRect4/TextureRect3/Label3"), NodePath("TextureRect4/TextureRect4/Label4"), NodePath("TextureRect4/TextureRect5/Label5")]
[node name="WaveCount" type="Label" parent="HUD"]
anchors_preset = 5
anchor_left = 0.5
anchor_right = 0.5
offset_left = -30.0
offset_top = 83.0
offset_right = 30.0
offset_bottom = 26.0
grow_horizontal = 2
theme_override_colors/font_color = Color(0, 0, 0, 1)
text = "1"
horizontal_alignment = 1
vertical_alignment = 1
[node name="EnemyCount" type="Label" parent="HUD"]
visible = false
offset_left = 10.0
offset_top = 80.0
offset_right = 123.0
offset_bottom = 106.0
text = "Enemies left: 0"
[node name="Crosshair" type="TextureRect" parent="HUD"]
texture_filter = 1
anchors_preset = 8
anchor_left = 0.5
anchor_top = 0.5
anchor_right = 0.5
anchor_bottom = 0.5
offset_left = -20.0
offset_top = -20.0
offset_right = 20.0
offset_bottom = 20.0
grow_horizontal = 2
grow_vertical = 2
mouse_filter = 2
texture = ExtResource("8_fq3f6")
[node name="TextureRect" type="TextureRect" parent="HUD"]
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
mouse_filter = 2
texture = SubResource("ViewportTexture_mk87g")
[node name="TextureRect2" type="TextureRect" parent="HUD"]
anchors_preset = 1
anchor_left = 1.0
anchor_right = 1.0
offset_left = -256.0
offset_top = 40.0
offset_right = -40.0
offset_bottom = 256.0
grow_horizontal = 0
mouse_filter = 2
texture = SubResource("ViewportTexture_574jy")
[node name="Label" type="Label" parent="HUD"]
anchors_preset = 1
anchor_left = 1.0
anchor_right = 1.0
offset_left = -40.0
offset_bottom = 26.0
grow_horizontal = 0
text = "FPS: "
horizontal_alignment = 2
vertical_alignment = 1
[node name="LivesBar" parent="HUD" instance=ExtResource("15_cqpib")]
anchors_preset = 0
anchor_right = 0.0
anchor_bottom = 0.0
offset_left = 10.0
offset_top = 10.0
offset_right = 214.0
offset_bottom = 32.0
grow_horizontal = 1
grow_vertical = 1
scale = Vector2(3, 3)
mouse_filter = 2
[node name="LivesCount" type="Label" parent="HUD"]
offset_left = -5.0
offset_top = 15.0
offset_right = 100.0
offset_bottom = 72.0
theme_override_colors/font_color = Color(0.65098, 0.227451, 0.243137, 1)
theme_override_font_sizes/font_size = 37
text = "120
"
horizontal_alignment = 1
vertical_alignment = 1
[node name="TextureRect3" type="TextureRect" parent="HUD"]
texture_filter = 1
anchors_preset = 1
anchor_left = 1.0
anchor_right = 1.0
offset_left = -262.0
offset_top = 37.0
offset_right = -37.0
offset_bottom = 336.0
grow_horizontal = 0
mouse_filter = 2
texture = ExtResource("16_x1xjr")
[node name="TextureRect4" type="TextureRect" parent="HUD"]
texture_filter = 1
anchors_preset = 5
@ -291,114 +400,6 @@ text = "999"
horizontal_alignment = 1
vertical_alignment = 1
[node name="WaveCount" type="Label" parent="HUD"]
anchors_preset = 5
anchor_left = 0.5
anchor_right = 0.5
offset_left = -30.0
offset_top = 83.0
offset_right = 30.0
offset_bottom = 26.0
grow_horizontal = 2
theme_override_colors/font_color = Color(0, 0, 0, 1)
text = "1"
horizontal_alignment = 1
vertical_alignment = 1
[node name="EnemyCount" type="Label" parent="HUD"]
visible = false
offset_left = 10.0
offset_top = 80.0
offset_right = 123.0
offset_bottom = 106.0
text = "Enemies left: 0"
[node name="Crosshair" type="TextureRect" parent="HUD"]
texture_filter = 1
anchors_preset = 8
anchor_left = 0.5
anchor_top = 0.5
anchor_right = 0.5
anchor_bottom = 0.5
offset_left = -20.0
offset_top = -20.0
offset_right = 20.0
offset_bottom = 20.0
grow_horizontal = 2
grow_vertical = 2
mouse_filter = 2
texture = ExtResource("8_fq3f6")
[node name="TextureRect" type="TextureRect" parent="HUD"]
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
mouse_filter = 2
texture = SubResource("ViewportTexture_mk87g")
[node name="TextureRect2" type="TextureRect" parent="HUD"]
anchors_preset = 1
anchor_left = 1.0
anchor_right = 1.0
offset_left = -256.0
offset_top = 40.0
offset_right = -40.0
offset_bottom = 256.0
grow_horizontal = 0
mouse_filter = 2
texture = SubResource("ViewportTexture_574jy")
[node name="Label" type="Label" parent="HUD"]
anchors_preset = 1
anchor_left = 1.0
anchor_right = 1.0
offset_left = -40.0
offset_bottom = 26.0
grow_horizontal = 0
text = "FPS: "
horizontal_alignment = 2
vertical_alignment = 1
[node name="LivesBar" parent="HUD" instance=ExtResource("15_cqpib")]
anchors_preset = 0
anchor_right = 0.0
anchor_bottom = 0.0
offset_left = 10.0
offset_top = 10.0
offset_right = 214.0
offset_bottom = 32.0
grow_horizontal = 1
grow_vertical = 1
scale = Vector2(3, 3)
mouse_filter = 2
[node name="LivesCount" type="Label" parent="HUD"]
offset_left = -5.0
offset_top = 15.0
offset_right = 100.0
offset_bottom = 72.0
theme_override_colors/font_color = Color(0.65098, 0.227451, 0.243137, 1)
theme_override_font_sizes/font_size = 37
text = "120
"
horizontal_alignment = 1
vertical_alignment = 1
[node name="TextureRect3" type="TextureRect" parent="HUD"]
texture_filter = 1
anchors_preset = 1
anchor_left = 1.0
anchor_right = 1.0
offset_left = -262.0
offset_top = 37.0
offset_right = -37.0
offset_bottom = 336.0
grow_horizontal = 0
mouse_filter = 2
texture = ExtResource("16_x1xjr")
[node name="Currency" type="Label" parent="HUD"]
anchors_preset = 1
anchor_left = 1.0