Compare commits
2 Commits
0513c3a3a6
...
74e4e47a68
Author | SHA1 | Date |
---|---|---|
|
74e4e47a68 | |
|
f2559cac32 |
|
@ -372,17 +372,17 @@ func _on_state_changed(state_name: StringName) -> void:
|
||||||
# Save collider and etc properties to the stack
|
# Save collider and etc properties to the stack
|
||||||
# and overwrite them with those provided by the state profile.
|
# and overwrite them with those provided by the state profile.
|
||||||
_property_save_restore_stack.push({
|
_property_save_restore_stack.push({
|
||||||
^".:_collider:rotation": (
|
^"_collider:rotation": (
|
||||||
Vector3.RIGHT*PI/2.0
|
Vector3.RIGHT*PI/2.0
|
||||||
if _current_state_properties.collider_horizontal
|
if _current_state_properties.collider_horizontal
|
||||||
else Vector3.ZERO
|
else Vector3.ZERO
|
||||||
),
|
),
|
||||||
^".:height": (
|
^"height": (
|
||||||
2.0*_current_state_properties.collider_radius
|
2.0*_current_state_properties.collider_radius
|
||||||
if _current_state_properties.collider_horizontal
|
if _current_state_properties.collider_horizontal
|
||||||
else _current_state_properties.collider_length
|
else _current_state_properties.collider_length
|
||||||
),
|
),
|
||||||
^".:width": (
|
^"width": (
|
||||||
_current_state_properties.collider_length
|
_current_state_properties.collider_length
|
||||||
if _current_state_properties.collider_horizontal
|
if _current_state_properties.collider_horizontal
|
||||||
else 2.0*_current_state_properties.collider_radius
|
else 2.0*_current_state_properties.collider_radius
|
||||||
|
@ -1232,7 +1232,7 @@ func _on_pick_up_state_tick(delta: float) -> void:
|
||||||
_do_standard_motion(delta)
|
_do_standard_motion(delta)
|
||||||
var target_displacement := (
|
var target_displacement := (
|
||||||
0.5*height*Vector3.UP +
|
0.5*height*Vector3.UP +
|
||||||
width*Vector3.FORWARD
|
0.75*width*Vector3.FORWARD
|
||||||
)
|
)
|
||||||
if !_carrying:
|
if !_carrying:
|
||||||
force_change_state(&'idle')
|
force_change_state(&'idle')
|
||||||
|
|
|
@ -576,6 +576,35 @@ invulnerable = false
|
||||||
etc = Dictionary[String, Variant]({})
|
etc = Dictionary[String, Variant]({})
|
||||||
metadata/_custom_type_script = "uid://vogde76hsl0j"
|
metadata/_custom_type_script = "uid://vogde76hsl0j"
|
||||||
|
|
||||||
|
[sub_resource type="Resource" id="Resource_ew8r5"]
|
||||||
|
script = ExtResource("4_qjty2")
|
||||||
|
use_coyote_time = false
|
||||||
|
coyote_time = 0.0
|
||||||
|
uninterruptible = true
|
||||||
|
is_carrying_state = true
|
||||||
|
equivalent_carrying_state = &""
|
||||||
|
animation_name = &"throw-equipped"
|
||||||
|
animation_alt_name = &""
|
||||||
|
animation_base_speed = 1.0
|
||||||
|
animation_blend_time = 0.25
|
||||||
|
animation_speedup_with_velocity = 0.0
|
||||||
|
audio = ExtResource("8_xab5e")
|
||||||
|
audio_volume_db = 0.0
|
||||||
|
collider_length = 1.0
|
||||||
|
collider_radius = 0.5
|
||||||
|
collider_horizontal = false
|
||||||
|
yaw_orientation = 0
|
||||||
|
pitch_orientation = 3
|
||||||
|
orientation_speed = 600.0
|
||||||
|
counts_as_grounded = true
|
||||||
|
physics_mode = 2
|
||||||
|
is_attack = false
|
||||||
|
attack_base_damage = 0.0
|
||||||
|
attack_base_knockback = 0.0
|
||||||
|
invulnerable = false
|
||||||
|
etc = Dictionary[String, Variant]({})
|
||||||
|
metadata/_custom_type_script = "uid://vogde76hsl0j"
|
||||||
|
|
||||||
[sub_resource type="Resource" id="Resource_tp4uk"]
|
[sub_resource type="Resource" id="Resource_tp4uk"]
|
||||||
script = ExtResource("4_qjty2")
|
script = ExtResource("4_qjty2")
|
||||||
use_coyote_time = false
|
use_coyote_time = false
|
||||||
|
@ -717,35 +746,6 @@ invulnerable = false
|
||||||
etc = Dictionary[String, Variant]({})
|
etc = Dictionary[String, Variant]({})
|
||||||
metadata/_custom_type_script = "uid://vogde76hsl0j"
|
metadata/_custom_type_script = "uid://vogde76hsl0j"
|
||||||
|
|
||||||
[sub_resource type="Resource" id="Resource_ew8r5"]
|
|
||||||
script = ExtResource("4_qjty2")
|
|
||||||
use_coyote_time = false
|
|
||||||
coyote_time = 0.0
|
|
||||||
uninterruptible = true
|
|
||||||
is_carrying_state = true
|
|
||||||
equivalent_carrying_state = &""
|
|
||||||
animation_name = &"throw-equipped"
|
|
||||||
animation_alt_name = &""
|
|
||||||
animation_base_speed = 1.0
|
|
||||||
animation_blend_time = 0.25
|
|
||||||
animation_speedup_with_velocity = 0.0
|
|
||||||
audio = ExtResource("8_xab5e")
|
|
||||||
audio_volume_db = 0.0
|
|
||||||
collider_length = 1.0
|
|
||||||
collider_radius = 0.5
|
|
||||||
collider_horizontal = false
|
|
||||||
yaw_orientation = 0
|
|
||||||
pitch_orientation = 3
|
|
||||||
orientation_speed = 600.0
|
|
||||||
counts_as_grounded = true
|
|
||||||
physics_mode = 2
|
|
||||||
is_attack = false
|
|
||||||
attack_base_damage = 0.0
|
|
||||||
attack_base_knockback = 0.0
|
|
||||||
invulnerable = false
|
|
||||||
etc = Dictionary[String, Variant]({})
|
|
||||||
metadata/_custom_type_script = "uid://vogde76hsl0j"
|
|
||||||
|
|
||||||
[sub_resource type="SphereShape3D" id="SphereShape3D_n51dc"]
|
[sub_resource type="SphereShape3D" id="SphereShape3D_n51dc"]
|
||||||
radius = 0.25
|
radius = 0.25
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue