Compare commits
No commits in common. "8465f2eadb0ad06fb9685eff57e93a65221e3052" and "9208a53c711ee485a4e002e2249a6be96acf0b6d" have entirely different histories.
8465f2eadb
...
9208a53c71
Binary file not shown.
Binary file not shown.
|
@ -1,7 +0,0 @@
|
||||||
extends Node3D
|
|
||||||
|
|
||||||
func _ready():
|
|
||||||
set_as_top_level(true)
|
|
||||||
|
|
||||||
func _process(delta):
|
|
||||||
global_transform.origin = $"../grape_man".get_pickup_bone_location()
|
|
Binary file not shown.
Binary file not shown.
|
@ -35,6 +35,9 @@ func get_pickup_bone_location() -> Vector3:
|
||||||
var trans = $rig/Skeleton3D.global_transform * $rig/Skeleton3D.get_bone_global_pose(pickup_bone_idx)
|
var trans = $rig/Skeleton3D.global_transform * $rig/Skeleton3D.get_bone_global_pose(pickup_bone_idx)
|
||||||
return trans.origin
|
return trans.origin
|
||||||
|
|
||||||
|
func _process(_delta):
|
||||||
|
print(get_pickup_bone_location())
|
||||||
|
|
||||||
func animation_key_pickup_completed():
|
func animation_key_pickup_completed():
|
||||||
pickup_animation_in_progress = false
|
pickup_animation_in_progress = false
|
||||||
emit_signal("pickup_animation_finished")
|
emit_signal("pickup_animation_finished")
|
||||||
|
|
BIN
godot/Models/grape_man.glb (Stored with Git LFS)
BIN
godot/Models/grape_man.glb (Stored with Git LFS)
Binary file not shown.
|
@ -5430,7 +5430,7 @@ _subresources={
|
||||||
"UpperBodyIdle": {
|
"UpperBodyIdle": {
|
||||||
"save_to_file/enabled": true,
|
"save_to_file/enabled": true,
|
||||||
"save_to_file/keep_custom_tracks": true,
|
"save_to_file/keep_custom_tracks": true,
|
||||||
"save_to_file/path": "res://Models/grape_animations/upper_body_idle.res",
|
"save_to_file/path": "res://Models/grape_animations/upper_body_idle.res.res",
|
||||||
"settings/loop_mode": 0,
|
"settings/loop_mode": 0,
|
||||||
"slice_1/end_frame": 0,
|
"slice_1/end_frame": 0,
|
||||||
"slice_1/loop_mode": 0,
|
"slice_1/loop_mode": 0,
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
[ext_resource type="Script" path="res://Models/grape_man.gd" id="2_ksje8"]
|
[ext_resource type="Script" path="res://Models/grape_man.gd" id="2_ksje8"]
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeAdd2" id="AnimationNodeAdd2_a0vxm"]
|
[sub_resource type="AnimationNodeAdd2" id="AnimationNodeAdd2_a0vxm"]
|
||||||
|
filter_enabled = true
|
||||||
filters = ["rig/Skeleton3D:forearm.L", "rig/Skeleton3D:forearm.R", "rig/Skeleton3D:head", "rig/Skeleton3D:upper_arm.L", "rig/Skeleton3D:upper_arm.R"]
|
filters = ["rig/Skeleton3D:forearm.L", "rig/Skeleton3D:forearm.R", "rig/Skeleton3D:head", "rig/Skeleton3D:upper_arm.L", "rig/Skeleton3D:upper_arm.R"]
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_s8uqe"]
|
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_s8uqe"]
|
||||||
|
@ -13,7 +14,7 @@ animation = &"UpperBodyIdle"
|
||||||
animation = &"Idle"
|
animation = &"Idle"
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeBlendTree" id="AnimationNodeBlendTree_ojr1k"]
|
[sub_resource type="AnimationNodeBlendTree" id="AnimationNodeBlendTree_ojr1k"]
|
||||||
graph_offset = Vector2(-74, 44)
|
graph_offset = Vector2(-312, -69)
|
||||||
nodes/Add2/node = SubResource("AnimationNodeAdd2_a0vxm")
|
nodes/Add2/node = SubResource("AnimationNodeAdd2_a0vxm")
|
||||||
nodes/Add2/position = Vector2(160, 80)
|
nodes/Add2/position = Vector2(160, 80)
|
||||||
nodes/Animation/node = SubResource("AnimationNodeAnimation_4ft7i")
|
nodes/Animation/node = SubResource("AnimationNodeAnimation_4ft7i")
|
||||||
|
@ -23,6 +24,7 @@ nodes/Animation/position = Vector2(0, 80)
|
||||||
node_connections = [&"output", 0, &"Add2", &"Add2", 0, &"Animation", &"Add2", 1, &"Animation 2"]
|
node_connections = [&"output", 0, &"Add2", &"Add2", 0, &"Animation", &"Add2", 1, &"Animation 2"]
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeAdd2" id="AnimationNodeAdd2_4gk6k"]
|
[sub_resource type="AnimationNodeAdd2" id="AnimationNodeAdd2_4gk6k"]
|
||||||
|
filter_enabled = true
|
||||||
filters = ["rig/Skeleton3D:forearm.L", "rig/Skeleton3D:forearm.R", "rig/Skeleton3D:head", "rig/Skeleton3D:upper_arm.L", "rig/Skeleton3D:upper_arm.R"]
|
filters = ["rig/Skeleton3D:forearm.L", "rig/Skeleton3D:forearm.R", "rig/Skeleton3D:head", "rig/Skeleton3D:upper_arm.L", "rig/Skeleton3D:upper_arm.R"]
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_alnh1"]
|
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_alnh1"]
|
||||||
|
@ -46,6 +48,7 @@ node_connections = [&"output", 0, &"Add2", &"Add2", 0, &"Animation", &"Add2", 1,
|
||||||
animation = &"Pickup"
|
animation = &"Pickup"
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeAdd2" id="AnimationNodeAdd2_rd6bn"]
|
[sub_resource type="AnimationNodeAdd2" id="AnimationNodeAdd2_rd6bn"]
|
||||||
|
filter_enabled = true
|
||||||
filters = ["rig/Skeleton3D:forearm.L", "rig/Skeleton3D:forearm.R", "rig/Skeleton3D:head", "rig/Skeleton3D:upper_arm.L", "rig/Skeleton3D:upper_arm.R"]
|
filters = ["rig/Skeleton3D:forearm.L", "rig/Skeleton3D:forearm.R", "rig/Skeleton3D:head", "rig/Skeleton3D:upper_arm.L", "rig/Skeleton3D:upper_arm.R"]
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_7s7tg"]
|
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_7s7tg"]
|
||||||
|
@ -55,7 +58,7 @@ animation = &"UpperBodyIdle"
|
||||||
animation = &"Walk"
|
animation = &"Walk"
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeBlendTree" id="AnimationNodeBlendTree_6rmmo"]
|
[sub_resource type="AnimationNodeBlendTree" id="AnimationNodeBlendTree_6rmmo"]
|
||||||
graph_offset = Vector2(-384.186, 6.2577)
|
graph_offset = Vector2(-358.186, -79.7423)
|
||||||
nodes/Add2/node = SubResource("AnimationNodeAdd2_rd6bn")
|
nodes/Add2/node = SubResource("AnimationNodeAdd2_rd6bn")
|
||||||
nodes/Add2/position = Vector2(140, 80)
|
nodes/Add2/position = Vector2(140, 80)
|
||||||
nodes/Animation/node = SubResource("AnimationNodeAnimation_ir63n")
|
nodes/Animation/node = SubResource("AnimationNodeAnimation_ir63n")
|
||||||
|
@ -65,6 +68,7 @@ nodes/Animation/position = Vector2(-40, 60)
|
||||||
node_connections = [&"output", 0, &"Add2", &"Add2", 0, &"Animation", &"Add2", 1, &"Animation 2"]
|
node_connections = [&"output", 0, &"Add2", &"Add2", 0, &"Animation", &"Add2", 1, &"Animation 2"]
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeAdd2" id="AnimationNodeAdd2_sv87c"]
|
[sub_resource type="AnimationNodeAdd2" id="AnimationNodeAdd2_sv87c"]
|
||||||
|
filter_enabled = true
|
||||||
filters = ["rig/Skeleton3D:forearm.L", "rig/Skeleton3D:forearm.R", "rig/Skeleton3D:head", "rig/Skeleton3D:upper_arm.L", "rig/Skeleton3D:upper_arm.R"]
|
filters = ["rig/Skeleton3D:forearm.L", "rig/Skeleton3D:forearm.R", "rig/Skeleton3D:head", "rig/Skeleton3D:upper_arm.L", "rig/Skeleton3D:upper_arm.R"]
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_y7bu0"]
|
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_y7bu0"]
|
||||||
|
@ -143,14 +147,14 @@ states/WalkEmpty/position = Vector2(548, 208)
|
||||||
states/WalkHold/node = SubResource("AnimationNodeBlendTree_kalnq")
|
states/WalkHold/node = SubResource("AnimationNodeBlendTree_kalnq")
|
||||||
states/WalkHold/position = Vector2(351, 323)
|
states/WalkHold/position = Vector2(351, 323)
|
||||||
transitions = ["Start", "IdleEmpty", SubResource("AnimationNodeStateMachineTransition_8sw6d"), "IdleEmpty", "WalkHold", SubResource("AnimationNodeStateMachineTransition_71rn8"), "WalkHold", "IdleEmpty", SubResource("AnimationNodeStateMachineTransition_cp7lp"), "WalkEmpty", "IdleEmpty", SubResource("AnimationNodeStateMachineTransition_27n2r"), "IdleEmpty", "WalkEmpty", SubResource("AnimationNodeStateMachineTransition_v26jl"), "IdleHold", "WalkHold", SubResource("AnimationNodeStateMachineTransition_u0rau"), "IdleHold", "WalkEmpty", SubResource("AnimationNodeStateMachineTransition_1hqga"), "WalkEmpty", "IdleHold", SubResource("AnimationNodeStateMachineTransition_uekhs"), "WalkHold", "IdleHold", SubResource("AnimationNodeStateMachineTransition_652wi"), "IdleEmpty", "Pickup", SubResource("AnimationNodeStateMachineTransition_sdgve"), "Pickup", "IdleEmpty", SubResource("AnimationNodeStateMachineTransition_otprv"), "IdleEmpty", "IdleHold", SubResource("AnimationNodeStateMachineTransition_fbwhh"), "IdleHold", "IdleEmpty", SubResource("AnimationNodeStateMachineTransition_4rq7a"), "WalkHold", "WalkEmpty", SubResource("AnimationNodeStateMachineTransition_oange"), "WalkEmpty", "WalkHold", SubResource("AnimationNodeStateMachineTransition_et4tx"), "Pickup", "IdleHold", SubResource("AnimationNodeStateMachineTransition_y2dr5")]
|
transitions = ["Start", "IdleEmpty", SubResource("AnimationNodeStateMachineTransition_8sw6d"), "IdleEmpty", "WalkHold", SubResource("AnimationNodeStateMachineTransition_71rn8"), "WalkHold", "IdleEmpty", SubResource("AnimationNodeStateMachineTransition_cp7lp"), "WalkEmpty", "IdleEmpty", SubResource("AnimationNodeStateMachineTransition_27n2r"), "IdleEmpty", "WalkEmpty", SubResource("AnimationNodeStateMachineTransition_v26jl"), "IdleHold", "WalkHold", SubResource("AnimationNodeStateMachineTransition_u0rau"), "IdleHold", "WalkEmpty", SubResource("AnimationNodeStateMachineTransition_1hqga"), "WalkEmpty", "IdleHold", SubResource("AnimationNodeStateMachineTransition_uekhs"), "WalkHold", "IdleHold", SubResource("AnimationNodeStateMachineTransition_652wi"), "IdleEmpty", "Pickup", SubResource("AnimationNodeStateMachineTransition_sdgve"), "Pickup", "IdleEmpty", SubResource("AnimationNodeStateMachineTransition_otprv"), "IdleEmpty", "IdleHold", SubResource("AnimationNodeStateMachineTransition_fbwhh"), "IdleHold", "IdleEmpty", SubResource("AnimationNodeStateMachineTransition_4rq7a"), "WalkHold", "WalkEmpty", SubResource("AnimationNodeStateMachineTransition_oange"), "WalkEmpty", "WalkHold", SubResource("AnimationNodeStateMachineTransition_et4tx"), "Pickup", "IdleHold", SubResource("AnimationNodeStateMachineTransition_y2dr5")]
|
||||||
graph_offset = Vector2(3, 172)
|
graph_offset = Vector2(26, 89)
|
||||||
|
|
||||||
[node name="grape_man" instance=ExtResource("1_fh5yr")]
|
[node name="grape_man" instance=ExtResource("1_fh5yr")]
|
||||||
transform = Transform3D(0.065, 0, 0, 0, 0.065, 0, 0, 0, 0.065, 0, 0, 0)
|
transform = Transform3D(0.065, 0, 0, 0, 0.065, 0, 0, 0, 0.065, 0, 0, 0)
|
||||||
script = ExtResource("2_ksje8")
|
script = ExtResource("2_ksje8")
|
||||||
|
|
||||||
[node name="Skeleton3D" parent="rig" index="0"]
|
[node name="Skeleton3D" parent="rig" index="0"]
|
||||||
bones/0/rotation = Quaternion(0.0970975, 0, 0, 0.995275)
|
bones/0/rotation = Quaternion(0.0889488, 0, 0, 0.996036)
|
||||||
bones/1/rotation = Quaternion(-0.0891896, 1.18734e-07, -1.06322e-08, 0.996015)
|
bones/1/rotation = Quaternion(-0.0891896, 1.18734e-07, -1.06322e-08, 0.996015)
|
||||||
bones/2/rotation = Quaternion(0.0133933, -1.19199e-07, 1.5966e-09, 0.99991)
|
bones/2/rotation = Quaternion(0.0133933, -1.19199e-07, 1.5966e-09, 0.99991)
|
||||||
bones/3/rotation = Quaternion(-0.00997737, 0.100365, -0.694951, 0.711948)
|
bones/3/rotation = Quaternion(-0.00997737, 0.100365, -0.694951, 0.711948)
|
||||||
|
|
|
@ -1,13 +1,10 @@
|
||||||
[gd_scene load_steps=6 format=3 uid="uid://7utef1nnena8"]
|
[gd_scene load_steps=4 format=3 uid="uid://7utef1nnena8"]
|
||||||
|
|
||||||
[ext_resource type="Script" path="res://Player.gd" id="1_7gpdp"]
|
[ext_resource type="Script" path="res://Player.gd" id="1_7gpdp"]
|
||||||
[ext_resource type="PackedScene" uid="uid://bgoo1lbt28na" path="res://Models/grape_man.tscn" id="2_hg0av"]
|
[ext_resource type="PackedScene" uid="uid://bgoo1lbt28na" path="res://Models/grape_man.tscn" id="2_hg0av"]
|
||||||
[ext_resource type="Script" path="res://Holster.gd" id="3_a68da"]
|
|
||||||
|
|
||||||
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_kb4ms"]
|
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_kb4ms"]
|
||||||
|
|
||||||
[sub_resource type="SphereShape3D" id="SphereShape3D_6l1w6"]
|
|
||||||
|
|
||||||
[node name="Player" type="CharacterBody3D"]
|
[node name="Player" type="CharacterBody3D"]
|
||||||
script = ExtResource("1_7gpdp")
|
script = ExtResource("1_7gpdp")
|
||||||
|
|
||||||
|
@ -24,13 +21,4 @@ transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 1.39043)
|
||||||
current = true
|
current = true
|
||||||
fov = 50.0
|
fov = 50.0
|
||||||
|
|
||||||
[node name="Holster" type="Node3D" parent="."]
|
|
||||||
script = ExtResource("3_a68da")
|
|
||||||
|
|
||||||
[node name="Area3D" type="Area3D" parent="Holster"]
|
|
||||||
|
|
||||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="Holster/Area3D"]
|
|
||||||
transform = Transform3D(0.1, 0, 0, 0, 0.1, 0, 0, 0, 0.1, 0, 0, 0)
|
|
||||||
shape = SubResource("SphereShape3D_6l1w6")
|
|
||||||
|
|
||||||
[connection signal="anim_check_grab" from="grape_man" to="." method="_on_grape_man_anim_check_grab"]
|
[connection signal="anim_check_grab" from="grape_man" to="." method="_on_grape_man_anim_check_grab"]
|
||||||
|
|
Loading…
Reference in New Issue