From c6264c0e49b4495fa07595d398464ef00a8bc626 Mon Sep 17 00:00:00 2001 From: osquallo Date: Fri, 27 Jul 2018 12:02:46 +0200 Subject: [PATCH] Remplissage de la jauge de douleur en cas de collision. --- scenes/GUI/GUI.tscn | 2 +- scenes/GUI/HUD/HUD.tscn | 310 ++++++++++++++++------------- scenes/GUI/HUD/douleur.gd | 20 ++ scenes/GUI/HUD/oubli.gd | 19 ++ scenes/GUI/HUD/trauma.gd | 20 ++ scenes/Game/Character/Character.gd | 6 +- scenes/Game/Game.tscn | 68 +++---- 7 files changed, 270 insertions(+), 175 deletions(-) create mode 100644 scenes/GUI/HUD/douleur.gd create mode 100644 scenes/GUI/HUD/oubli.gd create mode 100644 scenes/GUI/HUD/trauma.gd diff --git a/scenes/GUI/GUI.tscn b/scenes/GUI/GUI.tscn index e4734ed..7d12af1 100644 --- a/scenes/GUI/GUI.tscn +++ b/scenes/GUI/GUI.tscn @@ -60,7 +60,7 @@ _sections_unfolded = [ "Margin", "Size Flags", "Theme", "custom_constants" ] margin_left = 4.0 margin_top = 4.0 -margin_right = 139.0 +margin_right = 89.0 margin_bottom = 86.0 [connection signal="play_pressed" from="Home" to="." method="_on_Home_play_pressed"] diff --git a/scenes/GUI/HUD/HUD.tscn b/scenes/GUI/HUD/HUD.tscn index 8840d4e..760ae7d 100644 --- a/scenes/GUI/HUD/HUD.tscn +++ b/scenes/GUI/HUD/HUD.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=9 format=2] +[gd_scene load_steps=12 format=2] [ext_resource path="res://scenes/GUI/HUD/HUD.gd" type="Script" id=1] [ext_resource path="res://scenes/GUI/HUD/WindowControl.gd" type="Script" id=2] @@ -8,6 +8,9 @@ [ext_resource path="res://assets/GUI/images/button_open.png" type="Texture" id=6] [ext_resource path="res://assets/GUI/images/button_resize.png" type="Texture" id=7] [ext_resource path="res://scenes/GUI/MusicControls/MusicControls.tscn" type="PackedScene" id=8] +[ext_resource path="res://scenes/GUI/HUD/oubli.gd" type="Script" id=9] +[ext_resource path="res://scenes/GUI/HUD/trauma.gd" type="Script" id=10] +[ext_resource path="res://scenes/GUI/HUD/douleur.gd" type="Script" id=11] [node name="HUD" type="MarginContainer" index="0"] @@ -28,8 +31,26 @@ custom_constants/margin_bottom = 0 script = ExtResource( 1 ) _sections_unfolded = [ "Margin", "Mouse", "Rect", "Size Flags", "Theme", "Visibility", "custom_constants" ] -[node name="Windows" type="ReferenceRect" parent="." index="0"] +[node name="overlay_douleur" type="Panel" parent="." index="0"] +modulate = Color( 1, 0, 0, 0 ) +anchor_left = 0.0 +anchor_top = 0.0 +anchor_right = 0.0 +anchor_bottom = 0.0 +margin_right = 1024.0 +margin_bottom = 600.0 +rect_pivot_offset = Vector2( 0, 0 ) +rect_clip_content = false +mouse_filter = 0 +mouse_default_cursor_shape = 0 +size_flags_horizontal = 1 +size_flags_vertical = 1 +_sections_unfolded = [ "Visibility" ] + +[node name="Windows" type="ReferenceRect" parent="." index="1"] + +editor/display_folded = true anchor_left = 0.0 anchor_top = 0.0 anchor_right = 0.0 @@ -1049,7 +1070,7 @@ group = null texture_normal = ExtResource( 7 ) _sections_unfolded = [ "Mouse", "Size Flags", "Textures" ] -[node name="Music" parent="." index="1" instance=ExtResource( 8 )] +[node name="Music" parent="." index="2" instance=ExtResource( 8 )] margin_left = 942.0 margin_top = 0.0 @@ -1059,9 +1080,8 @@ size_flags_horizontal = 8 size_flags_vertical = 2 _sections_unfolded = [ "Size Flags" ] -[node name="Jauges" type="VBoxContainer" parent="." index="2"] +[node name="Jauges" type="VBoxContainer" parent="." index="3"] -editor/display_folded = true anchor_left = 0.0 anchor_top = 0.0 anchor_right = 0.0 @@ -1079,145 +1099,16 @@ size_flags_vertical = 10 alignment = 0 _sections_unfolded = [ "Size Flags" ] -[node name="douleur" type="HBoxContainer" parent="Jauges" index="0"] +[node name="oubli" type="HBoxContainer" parent="Jauges" index="0"] editor/display_folded = true +modulate = Color( 1, 1, 1, 0 ) anchor_left = 0.0 anchor_top = 0.0 anchor_right = 0.0 anchor_bottom = 0.0 -margin_right = 183.0 -margin_bottom = 16.0 -rect_pivot_offset = Vector2( 0, 0 ) -rect_clip_content = false -mouse_filter = 1 -mouse_default_cursor_shape = 0 -size_flags_horizontal = 0 -size_flags_vertical = 9 -alignment = 0 -_sections_unfolded = [ "Size Flags" ] - -[node name="ProgressBar" type="ProgressBar" parent="Jauges/douleur" index="0"] - -anchor_left = 0.0 -anchor_top = 0.0 -anchor_right = 0.0 -anchor_bottom = 0.0 -margin_right = 128.0 -margin_bottom = 16.0 -rect_min_size = Vector2( 128, 8 ) -rect_pivot_offset = Vector2( 0, 0 ) -rect_clip_content = false -mouse_filter = 0 -mouse_default_cursor_shape = 0 -size_flags_horizontal = 1 -size_flags_vertical = 0 -min_value = 0.0 -max_value = 100.0 -step = 1.0 -page = 0.0 -value = 0.0 -exp_edit = false -rounded = false -percent_visible = true -_sections_unfolded = [ "Percent", "Rect", "Size Flags" ] - -[node name="Label" type="Label" parent="Jauges/douleur" index="1"] - -anchor_left = 0.0 -anchor_top = 0.0 -anchor_right = 0.0 -anchor_bottom = 0.0 -margin_left = 132.0 -margin_top = 1.0 -margin_right = 183.0 -margin_bottom = 15.0 -rect_pivot_offset = Vector2( 0, 0 ) -rect_clip_content = false -mouse_filter = 2 -mouse_default_cursor_shape = 0 -size_flags_horizontal = 1 -size_flags_vertical = 4 -text = "Douleur" -percent_visible = 1.0 -lines_skipped = 0 -max_lines_visible = -1 - -[node name="trauma" type="HBoxContainer" parent="Jauges" index="1"] - -editor/display_folded = true -anchor_left = 0.0 -anchor_top = 0.0 -anchor_right = 0.0 -anchor_bottom = 0.0 -margin_top = 20.0 -margin_right = 179.0 -margin_bottom = 36.0 -rect_pivot_offset = Vector2( 0, 0 ) -rect_clip_content = false -mouse_filter = 1 -mouse_default_cursor_shape = 0 -size_flags_horizontal = 0 -size_flags_vertical = 9 -alignment = 0 -_sections_unfolded = [ "Size Flags" ] - -[node name="ProgressBar" type="ProgressBar" parent="Jauges/trauma" index="0"] - -anchor_left = 0.0 -anchor_top = 0.0 -anchor_right = 0.0 -anchor_bottom = 0.0 -margin_right = 128.0 -margin_bottom = 16.0 -rect_min_size = Vector2( 128, 8 ) -rect_pivot_offset = Vector2( 0, 0 ) -rect_clip_content = false -mouse_filter = 0 -mouse_default_cursor_shape = 0 -size_flags_horizontal = 1 -size_flags_vertical = 0 -min_value = 0.0 -max_value = 100.0 -step = 1.0 -page = 0.0 -value = 0.0 -exp_edit = false -rounded = false -percent_visible = true -_sections_unfolded = [ "Percent", "Rect", "Size Flags" ] - -[node name="Label" type="Label" parent="Jauges/trauma" index="1"] - -anchor_left = 0.0 -anchor_top = 0.0 -anchor_right = 0.0 -anchor_bottom = 0.0 -margin_left = 132.0 -margin_top = 1.0 -margin_right = 179.0 -margin_bottom = 15.0 -rect_pivot_offset = Vector2( 0, 0 ) -rect_clip_content = false -mouse_filter = 2 -mouse_default_cursor_shape = 0 -size_flags_horizontal = 1 -size_flags_vertical = 4 -text = "Trauma" -percent_visible = 1.0 -lines_skipped = 0 -max_lines_visible = -1 - -[node name="oubli" type="HBoxContainer" parent="Jauges" index="2"] - -editor/display_folded = true -anchor_left = 0.0 -anchor_top = 0.0 -anchor_right = 0.0 -anchor_bottom = 0.0 -margin_top = 40.0 margin_right = 167.0 -margin_bottom = 56.0 +margin_bottom = 16.0 rect_pivot_offset = Vector2( 0, 0 ) rect_clip_content = false mouse_filter = 1 @@ -1225,7 +1116,8 @@ mouse_default_cursor_shape = 0 size_flags_horizontal = 0 size_flags_vertical = 9 alignment = 0 -_sections_unfolded = [ "Size Flags" ] +script = ExtResource( 9 ) +_sections_unfolded = [ "Size Flags", "Visibility" ] [node name="ProgressBar" type="ProgressBar" parent="Jauges/oubli" index="0"] @@ -1273,7 +1165,141 @@ percent_visible = 1.0 lines_skipped = 0 max_lines_visible = -1 -[node name="SaveHUD" type="Button" parent="." index="3"] +[node name="trauma" type="HBoxContainer" parent="Jauges" index="1"] + +editor/display_folded = true +modulate = Color( 1, 1, 1, 0 ) +anchor_left = 0.0 +anchor_top = 0.0 +anchor_right = 0.0 +anchor_bottom = 0.0 +margin_top = 20.0 +margin_right = 179.0 +margin_bottom = 36.0 +rect_pivot_offset = Vector2( 0, 0 ) +rect_clip_content = false +mouse_filter = 1 +mouse_default_cursor_shape = 0 +size_flags_horizontal = 0 +size_flags_vertical = 9 +alignment = 0 +script = ExtResource( 10 ) +_sections_unfolded = [ "Size Flags", "Visibility" ] + +[node name="ProgressBar" type="ProgressBar" parent="Jauges/trauma" index="0"] + +anchor_left = 0.0 +anchor_top = 0.0 +anchor_right = 0.0 +anchor_bottom = 0.0 +margin_right = 128.0 +margin_bottom = 16.0 +rect_min_size = Vector2( 128, 8 ) +rect_pivot_offset = Vector2( 0, 0 ) +rect_clip_content = false +mouse_filter = 0 +mouse_default_cursor_shape = 0 +size_flags_horizontal = 1 +size_flags_vertical = 0 +min_value = 0.0 +max_value = 100.0 +step = 1.0 +page = 0.0 +value = 0.0 +exp_edit = false +rounded = false +percent_visible = true +_sections_unfolded = [ "Percent", "Rect", "Size Flags" ] + +[node name="Label" type="Label" parent="Jauges/trauma" index="1"] + +anchor_left = 0.0 +anchor_top = 0.0 +anchor_right = 0.0 +anchor_bottom = 0.0 +margin_left = 132.0 +margin_top = 1.0 +margin_right = 179.0 +margin_bottom = 15.0 +rect_pivot_offset = Vector2( 0, 0 ) +rect_clip_content = false +mouse_filter = 2 +mouse_default_cursor_shape = 0 +size_flags_horizontal = 1 +size_flags_vertical = 4 +text = "Trauma" +percent_visible = 1.0 +lines_skipped = 0 +max_lines_visible = -1 + +[node name="douleur" type="HBoxContainer" parent="Jauges" index="2"] + +editor/display_folded = true +modulate = Color( 1, 1, 1, 0 ) +anchor_left = 0.0 +anchor_top = 0.0 +anchor_right = 0.0 +anchor_bottom = 0.0 +margin_top = 40.0 +margin_right = 183.0 +margin_bottom = 56.0 +rect_pivot_offset = Vector2( 0, 0 ) +rect_clip_content = false +mouse_filter = 1 +mouse_default_cursor_shape = 0 +size_flags_horizontal = 0 +size_flags_vertical = 9 +alignment = 0 +script = ExtResource( 11 ) +_sections_unfolded = [ "Size Flags", "Visibility" ] + +[node name="ProgressBar" type="ProgressBar" parent="Jauges/douleur" index="0"] + +anchor_left = 0.0 +anchor_top = 0.0 +anchor_right = 0.0 +anchor_bottom = 0.0 +margin_right = 128.0 +margin_bottom = 16.0 +rect_min_size = Vector2( 128, 8 ) +rect_pivot_offset = Vector2( 0, 0 ) +rect_clip_content = false +mouse_filter = 0 +mouse_default_cursor_shape = 0 +size_flags_horizontal = 1 +size_flags_vertical = 0 +min_value = 0.0 +max_value = 100.0 +step = 1.0 +page = 0.0 +value = 0.0 +exp_edit = false +rounded = false +percent_visible = true +_sections_unfolded = [ "Percent", "Rect", "Size Flags" ] + +[node name="Label" type="Label" parent="Jauges/douleur" index="1"] + +anchor_left = 0.0 +anchor_top = 0.0 +anchor_right = 0.0 +anchor_bottom = 0.0 +margin_left = 132.0 +margin_top = 1.0 +margin_right = 183.0 +margin_bottom = 15.0 +rect_pivot_offset = Vector2( 0, 0 ) +rect_clip_content = false +mouse_filter = 2 +mouse_default_cursor_shape = 0 +size_flags_horizontal = 1 +size_flags_vertical = 4 +text = "Douleur" +percent_visible = 1.0 +lines_skipped = 0 +max_lines_visible = -1 + +[node name="SaveHUD" type="Button" parent="." index="4"] anchor_left = 0.0 anchor_top = 0.0 @@ -1329,6 +1355,12 @@ _sections_unfolded = [ "Size Flags" ] [connection signal="pressed" from="Windows/Music/VBoxContainer/Footer/HBoxContainer/Resize" to="Windows/Music" method="_on_Resize_pressed"] +[connection signal="value_changed" from="Jauges/oubli/ProgressBar" to="Jauges/oubli" method="_on_ProgressBar_value_changed"] + +[connection signal="value_changed" from="Jauges/trauma/ProgressBar" to="Jauges/trauma" method="_on_ProgressBar_value_changed"] + +[connection signal="value_changed" from="Jauges/douleur/ProgressBar" to="Jauges/douleur" method="_on_ProgressBar_value_changed"] + [connection signal="pressed" from="SaveHUD" to="." method="_on_SaveHUD_pressed"] diff --git a/scenes/GUI/HUD/douleur.gd b/scenes/GUI/HUD/douleur.gd new file mode 100644 index 0000000..01aa97a --- /dev/null +++ b/scenes/GUI/HUD/douleur.gd @@ -0,0 +1,20 @@ +extends HBoxContainer + +# class member variables go here, for example: +# var a = 2 +# var b = "textvar" + +func _ready(): + # Called when the node is added to the scene for the first time. + # Initialization here + pass + +#func _process(delta): +# # Called every frame. Delta is time since last frame. +# # Update game logic here. +# pass + + +func _on_ProgressBar_value_changed(value): + self.modulate = Color( 1.0, 1.0, 1.0, clamp(value/50, 0.4, 1 ) ) + get_node( "../../overlay_douleur" ).modulate.a = self.modulate.a/2 diff --git a/scenes/GUI/HUD/oubli.gd b/scenes/GUI/HUD/oubli.gd new file mode 100644 index 0000000..adea93d --- /dev/null +++ b/scenes/GUI/HUD/oubli.gd @@ -0,0 +1,19 @@ +extends HBoxContainer + +# class member variables go here, for example: +# var a = 2 +# var b = "textvar" + +func _ready(): + # Called when the node is added to the scene for the first time. + # Initialization here + pass + +#func _process(delta): +# # Called every frame. Delta is time since last frame. +# # Update game logic here. +# pass + + +func _on_ProgressBar_value_changed(value): + self.modulate = Color( 1.0, 1.0, 1.0, clamp(value/50, 20/255, 1 ) ) \ No newline at end of file diff --git a/scenes/GUI/HUD/trauma.gd b/scenes/GUI/HUD/trauma.gd new file mode 100644 index 0000000..6d24ea0 --- /dev/null +++ b/scenes/GUI/HUD/trauma.gd @@ -0,0 +1,20 @@ +extends HBoxContainer + +# class member variables go here, for example: +# var a = 2 +# var b = "textvar" + +func _ready(): + # Called when the node is added to the scene for the first time. + # Initialization here + pass + +#func _process(delta): +# # Called every frame. Delta is time since last frame. +# # Update game logic here. +# pass + + + +func _on_ProgressBar_value_changed(value): + self.modulate = Color( 1.0, 1.0, 1.0, clamp(value/50, 20/255, 1 ) ) \ No newline at end of file diff --git a/scenes/Game/Character/Character.gd b/scenes/Game/Character/Character.gd index aefecc3..f5de84c 100644 --- a/scenes/Game/Character/Character.gd +++ b/scenes/Game/Character/Character.gd @@ -90,7 +90,11 @@ func process_movement(delta): obj.apply_impulse( collision_info.position, -collision_info.normal*delta ) if not obj.get_node( "MeshInstance" ).get_surface_material(0).get("albedo_color") == null: obj.get_node( "MeshInstance" ).get_surface_material(0).albedo_color = Color( 1, 0, 1, 1 ) - + get_node( "../../GUI/HUD/Jauges/douleur/ProgressBar" ).value += 0.1 + if get_node( "../../GUI/HUD/Jauges/douleur/ProgressBar" ).value >= 100: + get_node( "../../GUI/HUD/Jauges/trauma/ProgressBar" ).value += 0.1 + if get_node( "../../GUI/HUD/Jauges/trauma/ProgressBar" ).value >= 100: + get_node( "../../GUI/HUD/Jauges/oubli/ProgressBar" ).value += 0.1 # obj.get_node( "MeshInstance" ).get_surface_material(0).albedo_color = Color( collision_info.normal ) # if obj.has_method( "hit" ): # obj.hit( collision_info.position, collision_info.collider_velocity ) diff --git a/scenes/Game/Game.tscn b/scenes/Game/Game.tscn index 2114e84..6a4ed87 100644 --- a/scenes/Game/Game.tscn +++ b/scenes/Game/Game.tscn @@ -12,7 +12,7 @@ [ext_resource path="res://assets/Game/textures/fire_01.png" type="Texture" id=10] [ext_resource path="res://assets/Game/textures/fire_02.png" type="Texture" id=11] -[sub_resource type="GDScript" id=12] +[sub_resource type="GDScript" id=1] script/source = "extends RigidBody @@ -22,7 +22,7 @@ func _on_Box_sleeping_state_changed(): else: $MeshInstance.get_surface_material(0).albedo_color = Color( 0.0, 0.0, 1.0, 1 )" -[sub_resource type="CubeMesh" id=5] +[sub_resource type="CubeMesh" id=2] custom_aabb = AABB( 0, 0, 0, 0, 0, 0 ) size = Vector3( 2, 2, 2 ) @@ -30,7 +30,7 @@ subdivide_width = 0 subdivide_height = 0 subdivide_depth = 0 -[sub_resource type="SpatialMaterial" id=6] +[sub_resource type="SpatialMaterial" id=3] render_priority = 0 flags_transparent = false @@ -95,11 +95,11 @@ proximity_fade_enable = false distance_fade_enable = false _sections_unfolded = [ "Albedo", "Ambient Occlusion", "Clearcoat", "Depth", "Detail", "Distance Fade", "Flags", "Metallic", "NormalMap", "Proximity Fade", "Rim", "Roughness", "Subsurf Scatter", "Transmission", "Vertex Color" ] -[sub_resource type="ConvexPolygonShape" id=7] +[sub_resource type="ConvexPolygonShape" id=4] points = PoolVector3Array( -1, 1, 1, 1, 1, -1, 1, 1, 1, -1, 1, -1, -1, -1, 1, 1, -1, -1, 1, -1, 1, -1, -1, -1, 1, 1, 1, -1, 1, -1, 1, 1, -1, -1, 1, 1, 1, -1, 1, -1, -1, -1, 1, -1, -1, -1, -1, 1, 1, 1, 1, -1, -1, 1, -1, 1, 1, 1, -1, 1, 1, 1, -1, -1, -1, -1, -1, 1, -1, 1, -1, -1 ) -[sub_resource type="GDScript" id=13] +[sub_resource type="GDScript" id=5] script/source = "extends RigidBody @@ -109,7 +109,7 @@ func _on_Box_sleeping_state_changed(): else: $MeshInstance.get_surface_material(0).albedo_color = Color( 0.0, 0.0, 1.0, 1 )" -[sub_resource type="SpatialMaterial" id=8] +[sub_resource type="SpatialMaterial" id=6] render_priority = 0 flags_transparent = false @@ -169,13 +169,13 @@ proximity_fade_enable = false distance_fade_enable = false _sections_unfolded = [ "Albedo", "Emission", "Flags", "Parameters", "Particles Anim" ] -[sub_resource type="QuadMesh" id=9] +[sub_resource type="QuadMesh" id=7] -material = SubResource( 8 ) +material = SubResource( 6 ) custom_aabb = AABB( 0, 0, 0, 0, 0, 0 ) size = Vector2( 0.4, 0.4 ) -[sub_resource type="SpatialMaterial" id=10] +[sub_resource type="SpatialMaterial" id=8] render_priority = 0 flags_transparent = false @@ -236,13 +236,13 @@ proximity_fade_enable = false distance_fade_enable = false _sections_unfolded = [ "Albedo", "Emission", "Flags", "Parameters", "Particles Anim" ] -[sub_resource type="QuadMesh" id=11] +[sub_resource type="QuadMesh" id=9] -material = SubResource( 10 ) +material = SubResource( 8 ) custom_aabb = AABB( 0, 0, 0, 0, 0, 0 ) size = Vector2( 0.4, 0.4 ) -[node name="Game" type="Spatial" index="0"] +[node name="Game" type="Spatial"] [node name="Character" parent="." index="0" instance=ExtResource( 1 )] @@ -302,7 +302,7 @@ linear_velocity = Vector3( 0, 0, 0 ) linear_damp = -1.0 angular_velocity = Vector3( 0, 0, 0 ) angular_damp = -1.0 -script = SubResource( 12 ) +script = SubResource( 1 ) _sections_unfolded = [ "Collision" ] [node name="MeshInstance" type="MeshInstance" parent="World/Box" index="0"] @@ -317,15 +317,15 @@ lod_min_distance = 0.0 lod_min_hysteresis = 0.0 lod_max_distance = 0.0 lod_max_hysteresis = 0.0 -mesh = SubResource( 5 ) +mesh = SubResource( 2 ) skeleton = NodePath("..") -material/0 = SubResource( 6 ) +material/0 = SubResource( 3 ) _sections_unfolded = [ "Geometry", "LOD", "material" ] [node name="CollisionShape" type="CollisionShape" parent="World/Box" index="1"] transform = Transform( 1, -1.49012e-008, 0, 2.68221e-007, 1, -1.19209e-007, -2.98023e-008, 2.68221e-007, 1, 0.0507725, -0.0524313, 0.0583506 ) -shape = SubResource( 7 ) +shape = SubResource( 4 ) disabled = false _sections_unfolded = [ "Transform" ] @@ -358,7 +358,7 @@ linear_velocity = Vector3( 0, 0, 0 ) linear_damp = -1.0 angular_velocity = Vector3( 0, 0, 0 ) angular_damp = -1.0 -script = SubResource( 12 ) +script = SubResource( 1 ) _sections_unfolded = [ "Collision", "Transform" ] [node name="MeshInstance" type="MeshInstance" parent="World/Box3" index="0"] @@ -373,15 +373,15 @@ lod_min_distance = 0.0 lod_min_hysteresis = 0.0 lod_max_distance = 0.0 lod_max_hysteresis = 0.0 -mesh = SubResource( 5 ) +mesh = SubResource( 2 ) skeleton = NodePath("..") -material/0 = SubResource( 6 ) +material/0 = SubResource( 3 ) _sections_unfolded = [ "Geometry", "LOD", "material" ] [node name="CollisionShape" type="CollisionShape" parent="World/Box3" index="1"] transform = Transform( 1, 1.49012e-008, 0, 1.3411e-007, 1, 0, 2.98023e-008, -2.98023e-008, 1, 0, 0, 0 ) -shape = SubResource( 7 ) +shape = SubResource( 4 ) disabled = false _sections_unfolded = [ "Transform" ] @@ -414,7 +414,7 @@ linear_velocity = Vector3( 0, 0, 0 ) linear_damp = -1.0 angular_velocity = Vector3( 0, 0, 0 ) angular_damp = -1.0 -script = SubResource( 12 ) +script = SubResource( 1 ) _sections_unfolded = [ "Collision", "Transform" ] [node name="MeshInstance" type="MeshInstance" parent="World/Box5" index="0"] @@ -429,15 +429,15 @@ lod_min_distance = 0.0 lod_min_hysteresis = 0.0 lod_max_distance = 0.0 lod_max_hysteresis = 0.0 -mesh = SubResource( 5 ) +mesh = SubResource( 2 ) skeleton = NodePath("..") -material/0 = SubResource( 6 ) +material/0 = SubResource( 3 ) _sections_unfolded = [ "Geometry", "LOD", "material" ] [node name="CollisionShape" type="CollisionShape" parent="World/Box5" index="1"] transform = Transform( 1, 1.49012e-008, 0, 1.3411e-007, 1, 0, 2.98023e-008, -2.98023e-008, 1, 0, 0, 0 ) -shape = SubResource( 7 ) +shape = SubResource( 4 ) disabled = false _sections_unfolded = [ "Transform" ] @@ -470,7 +470,7 @@ linear_velocity = Vector3( 0, 0, 0 ) linear_damp = -1.0 angular_velocity = Vector3( 0, 0, 0 ) angular_damp = -1.0 -script = SubResource( 12 ) +script = SubResource( 1 ) _sections_unfolded = [ "Collision", "Transform" ] [node name="MeshInstance" type="MeshInstance" parent="World/Box4" index="0"] @@ -485,15 +485,15 @@ lod_min_distance = 0.0 lod_min_hysteresis = 0.0 lod_max_distance = 0.0 lod_max_hysteresis = 0.0 -mesh = SubResource( 5 ) +mesh = SubResource( 2 ) skeleton = NodePath("..") -material/0 = SubResource( 6 ) +material/0 = SubResource( 3 ) _sections_unfolded = [ "Geometry", "LOD", "material" ] [node name="CollisionShape" type="CollisionShape" parent="World/Box4" index="1"] transform = Transform( 1, 1.49012e-008, 0, 1.3411e-007, 1, 0, 2.98023e-008, -2.98023e-008, 1, 0, 0, 0 ) -shape = SubResource( 7 ) +shape = SubResource( 4 ) disabled = false _sections_unfolded = [ "Transform" ] @@ -526,7 +526,7 @@ linear_velocity = Vector3( 0, 0, 0 ) linear_damp = -1.0 angular_velocity = Vector3( 0, 0, 0 ) angular_damp = -1.0 -script = SubResource( 13 ) +script = SubResource( 5 ) _sections_unfolded = [ "Collision" ] [node name="MeshInstance" type="MeshInstance" parent="World/Box2" index="0"] @@ -541,15 +541,15 @@ lod_min_distance = 0.0 lod_min_hysteresis = 0.0 lod_max_distance = 0.0 lod_max_hysteresis = 0.0 -mesh = SubResource( 5 ) +mesh = SubResource( 2 ) skeleton = NodePath("..") -material/0 = SubResource( 6 ) +material/0 = SubResource( 3 ) _sections_unfolded = [ "Geometry", "LOD", "Visibility", "material" ] [node name="CollisionShape" type="CollisionShape" parent="World/Box2" index="1"] transform = Transform( 1, 1.49012e-008, 0, 1.3411e-007, 1, 0, 2.98023e-008, -2.98023e-008, 1, 0, 0, 0 ) -shape = SubResource( 7 ) +shape = SubResource( 4 ) disabled = false _sections_unfolded = [ "Transform" ] @@ -564,8 +564,8 @@ bounce = 0.75 transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -4.60514, 0.220215, -2.3728 ) visibility_aabb = AABB( -4, -4.04395, -3.96729, 8, 8, 8 ) draw_passes = 2 -draw_pass_1 = SubResource( 9 ) -draw_pass_2 = SubResource( 11 ) +draw_pass_1 = SubResource( 7 ) +draw_pass_2 = SubResource( 9 ) [connection signal="sleeping_state_changed" from="World/Box" to="World/Box" method="_on_Box_sleeping_state_changed"]