temp: better state chart but without the functionnality
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
[gd_scene load_steps=32 format=3 uid="uid://bei4nhkf8lwdo"]
|
||||
[gd_scene load_steps=33 format=3 uid="uid://bei4nhkf8lwdo"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://bbbrf5ckydfna" path="res://player_controller/Scripts/PlayerController.cs" id="1_poq2x"]
|
||||
[ext_resource type="Resource" uid="uid://bl5crtu1gkrtr" path="res://systems/inputs/base_mode/base_mode.tres" id="3_cresl"]
|
||||
@ -27,6 +27,7 @@
|
||||
[ext_resource type="Script" uid="uid://couw105c3bde4" path="res://addons/godot_state_charts/state_chart.gd" id="25_wv70j"]
|
||||
[ext_resource type="Script" uid="uid://jk2jm1g6q853" path="res://addons/godot_state_charts/compound_state.gd" id="26_infe6"]
|
||||
[ext_resource type="Script" uid="uid://cytafq8i1y8qm" path="res://addons/godot_state_charts/atomic_state.gd" id="27_34snm"]
|
||||
[ext_resource type="Script" uid="uid://c1vp0ojjvaby1" path="res://addons/godot_state_charts/parallel_state.gd" id="27_infe6"]
|
||||
[ext_resource type="Script" uid="uid://cf1nsco3w0mf6" path="res://addons/godot_state_charts/transition.gd" id="28_n7qhm"]
|
||||
[ext_resource type="PackedScene" uid="uid://ckm3d6k08a72u" path="res://systems/weapon/weapon.tscn" id="29_wv70j"]
|
||||
|
||||
@ -129,77 +130,6 @@ offset_bottom = 1.0
|
||||
enabled = false
|
||||
initial_node_to_watch = NodePath("../StateChart")
|
||||
|
||||
[node name="StateChart" type="Node" parent="."]
|
||||
script = ExtResource("25_wv70j")
|
||||
metadata/_custom_type_script = "uid://couw105c3bde4"
|
||||
|
||||
[node name="Root" type="Node" parent="StateChart"]
|
||||
script = ExtResource("26_infe6")
|
||||
initial_state = NodePath("WeaponInHand")
|
||||
|
||||
[node name="WeaponInHand" type="Node" parent="StateChart/Root"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="ToAiming" type="Node" parent="StateChart/Root/WeaponInHand"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Aiming")
|
||||
event = &"aim_pressed"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="Aiming" type="Node" parent="StateChart/Root"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="ToWeaponInHand" type="Node" parent="StateChart/Root/Aiming"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../WeaponInHand")
|
||||
event = &"aim_canceled"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="ToDashing" type="Node" parent="StateChart/Root/Aiming"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Dashing")
|
||||
event = &"aim_released"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="ToWeaponThrown" type="Node" parent="StateChart/Root/Aiming"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../WeaponThrown")
|
||||
event = &"hit_pressed"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="Dashing" type="Node" parent="StateChart/Root"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="ToWeaponInHand" type="Node" parent="StateChart/Root/Dashing"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../WeaponInHand")
|
||||
event = &"dash_ended"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="ToHanging" type="Node" parent="StateChart/Root/Dashing"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Hanging")
|
||||
event = &"dash_to_planted"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="WeaponThrown" type="Node" parent="StateChart/Root"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="ToDashing" type="Node" parent="StateChart/Root/WeaponThrown"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Dashing")
|
||||
event = &"aim_pressed"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="Hanging" type="Node" parent="StateChart/Root"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="ToWeaponInHand" type="Node" parent="StateChart/Root/Hanging"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../WeaponInHand")
|
||||
event = &"jump"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="WeaponRoot" type="Node3D" parent="."]
|
||||
|
||||
[node name="WeaponSystem" parent="WeaponRoot" instance=ExtResource("29_wv70j")]
|
||||
@ -207,6 +137,161 @@ transform = Transform3D(1, 0, 0, 0, 0.173648, -0.984808, 0, 0.984808, 0.173648,
|
||||
ThrowForce = 25.0
|
||||
StraightThrowDuration = 0.07
|
||||
|
||||
[node name="StateChart" type="Node" parent="."]
|
||||
script = ExtResource("25_wv70j")
|
||||
metadata/_custom_type_script = "uid://couw105c3bde4"
|
||||
|
||||
[node name="Root" type="Node" parent="StateChart"]
|
||||
script = ExtResource("27_infe6")
|
||||
|
||||
[node name="Actions" type="Node" parent="StateChart/Root"]
|
||||
script = ExtResource("26_infe6")
|
||||
initial_state = NodePath("WeaponInHand")
|
||||
metadata/_custom_type_script = "uid://c1vp0ojjvaby1"
|
||||
|
||||
[node name="WeaponInHand" type="Node" parent="StateChart/Root/Actions"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="ToAiming" type="Node" parent="StateChart/Root/Actions/WeaponInHand"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Aiming")
|
||||
event = &"aim_pressed"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="Aiming" type="Node" parent="StateChart/Root/Actions"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="ToWeaponInHand" type="Node" parent="StateChart/Root/Actions/Aiming"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../WeaponInHand")
|
||||
event = &"aim_canceled"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="ToDashing" type="Node" parent="StateChart/Root/Actions/Aiming"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Dashing")
|
||||
event = &"aim_released"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="ToWeaponThrown" type="Node" parent="StateChart/Root/Actions/Aiming"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../WeaponThrown")
|
||||
event = &"hit_pressed"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="Dashing" type="Node" parent="StateChart/Root/Actions"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="ToWeaponInHand" type="Node" parent="StateChart/Root/Actions/Dashing"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../WeaponInHand")
|
||||
event = &"dash_ended"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="ToHanging" type="Node" parent="StateChart/Root/Actions/Dashing"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Hanging")
|
||||
event = &"dash_to_planted"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="WeaponThrown" type="Node" parent="StateChart/Root/Actions"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="ToDashing" type="Node" parent="StateChart/Root/Actions/WeaponThrown"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Dashing")
|
||||
event = &"aim_pressed"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="Hanging" type="Node" parent="StateChart/Root/Actions"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="ToWeaponInHand" type="Node" parent="StateChart/Root/Actions/Hanging"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../WeaponInHand")
|
||||
event = &"jump"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="Movement" type="Node" parent="StateChart/Root"]
|
||||
script = ExtResource("26_infe6")
|
||||
initial_state = NodePath("Grounded")
|
||||
|
||||
[node name="Grounded" type="Node" parent="StateChart/Root/Movement"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="OnJump" type="Node" parent="StateChart/Root/Movement/Grounded"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Airborne/DoubleJumpEnabled")
|
||||
event = &"jump"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="OnAirborne" type="Node" parent="StateChart/Root/Movement/Grounded"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Airborne/CoyoteEnabled")
|
||||
event = &"start_falling"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="Hanging" type="Node" parent="StateChart/Root/Movement"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="OnJump" type="Node" parent="StateChart/Root/Movement/Hanging"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Airborne/DoubleJumpEnabled")
|
||||
event = &"jump"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="WallHugging" type="Node" parent="StateChart/Root/Movement"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="OnJump" type="Node" parent="StateChart/Root/Movement/WallHugging"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Airborne/DoubleJumpEnabled")
|
||||
event = &"jump"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="OnLeaveWall" type="Node" parent="StateChart/Root/Movement/WallHugging"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Airborne/CoyoteEnabled")
|
||||
event = &"start_falling"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="Airborne" type="Node" parent="StateChart/Root/Movement"]
|
||||
script = ExtResource("26_infe6")
|
||||
initial_state = NodePath("CoyoteEnabled")
|
||||
|
||||
[node name="OnGrounded" type="Node" parent="StateChart/Root/Movement/Airborne"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Grounded")
|
||||
event = &"grounded"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="CoyoteEnabled" type="Node" parent="StateChart/Root/Movement/Airborne"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="OnJump" type="Node" parent="StateChart/Root/Movement/Airborne/CoyoteEnabled"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../DoubleJumpEnabled")
|
||||
event = &"jump"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="OnExpiration" type="Node" parent="StateChart/Root/Movement/Airborne/CoyoteEnabled"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../DoubleJumpEnabled")
|
||||
event = &"coyote_expired"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="DoubleJumpEnabled" type="Node" parent="StateChart/Root/Movement/Airborne"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[node name="OnJump" type="Node" parent="StateChart/Root/Movement/Airborne/DoubleJumpEnabled"]
|
||||
script = ExtResource("28_n7qhm")
|
||||
to = NodePath("../../Falling")
|
||||
event = &"jump"
|
||||
delay_in_seconds = "0.0"
|
||||
|
||||
[node name="Falling" type="Node" parent="StateChart/Root/Movement/Airborne"]
|
||||
script = ExtResource("27_34snm")
|
||||
|
||||
[connection signal="input_aim_canceled" from="InputController" to="." method="OnInputAimCanceled"]
|
||||
[connection signal="input_aim_pressed" from="InputController" to="." method="OnInputAimPressed"]
|
||||
[connection signal="input_aim_released" from="InputController" to="." method="OnInputAimReleased"]
|
||||
|
Reference in New Issue
Block a user