feat: updated rifle texture, turning animation

This commit is contained in:
Sara 2024-12-01 21:38:30 +01:00
parent 92f31aa85b
commit efc8006c66
28 changed files with 7376 additions and 114 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View file

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:dac3325bf581718e44b20aa4cd96fca882350e730218ac70da6efe669b5abb77
size 974656
oid sha256:02bb57a7618cdb5a9710f81dda9d106fa65b42388ddfc54c4737d8892d80e811
size 1557812

File diff suppressed because it is too large Load diff

View file

@ -2,15 +2,12 @@
importer="texture"
type="CompressedTexture2D"
uid="uid://03bidmgkyu7x"
uid="uid://bpbh6yad5us1u"
path.s3tc="res://.godot/imported/character_grid.png-2d0e906f71f3e26d2c036075a68637c9.s3tc.ctex"
metadata={
"imported_formats": ["s3tc_bptc"],
"vram_texture": true
}
generator_parameters={
"md5": "5251a685620ecec968e08d819a2a66a5"
}
[deps]

View file

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:da6fd2aa2650150467a3ec08d9bd37d7545057fce020e453354ddd3f3d643675
size 30156

View file

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:da6fd2aa2650150467a3ec08d9bd37d7545057fce020e453354ddd3f3d643675
size 30156

View file

@ -1,38 +0,0 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://bfbggseqfivqg"
path.s3tc="res://.godot/imported/character_lee_enfield.jpg-6d1650ff6ac73c0058d6c5c97b6347e0.s3tc.ctex"
metadata={
"imported_formats": ["s3tc_bptc"],
"vram_texture": true
}
generator_parameters={
"md5": "2f63e7aacd33f2b1b77cb71dd6821df5"
}
[deps]
source_file="res://models/character_lee_enfield.jpg"
dest_files=["res://.godot/imported/character_lee_enfield.jpg-6d1650ff6ac73c0058d6c5c97b6347e0.s3tc.ctex"]
[params]
compress/mode=2
compress/high_quality=false
compress/lossy_quality=0.7
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=true
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=0

View file

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:a28ab4d7a0be49abfb5de55ed47c05dfa2778649794b37755e8afd71407e5ef8
size 381127

View file

@ -2,20 +2,17 @@
importer="texture"
type="CompressedTexture2D"
uid="uid://bwq5navx6qi1l"
path.s3tc="res://.godot/imported/character_lee-enfield.jpg-8aa5d8a65848beefe70a765079e8bd2c.s3tc.ctex"
uid="uid://b2y2j72db80od"
path.s3tc="res://.godot/imported/character_rifle.png-59d3a7b80c91b62335b799778e2ab8de.s3tc.ctex"
metadata={
"imported_formats": ["s3tc_bptc"],
"vram_texture": true
}
generator_parameters={
"md5": "2f63e7aacd33f2b1b77cb71dd6821df5"
}
[deps]
source_file="res://models/character_lee-enfield.jpg"
dest_files=["res://.godot/imported/character_lee-enfield.jpg-8aa5d8a65848beefe70a765079e8bd2c.s3tc.ctex"]
source_file="res://models/character_rifle.png"
dest_files=["res://.godot/imported/character_rifle.png-59d3a7b80c91b62335b799778e2ab8de.s3tc.ctex"]
[params]

View file

@ -1,11 +1,10 @@
[gd_resource type="StandardMaterial3D" load_steps=2 format=3 uid="uid://dibu06h02xpdh"]
[ext_resource type="Texture2D" uid="uid://bfbggseqfivqg" path="res://models/character_lee_enfield.jpg" id="1_8jtmf"]
[ext_resource type="Texture2D" uid="uid://b2y2j72db80od" path="res://models/character_rifle.png" id="1_iex1v"]
[resource]
resource_name = "Material"
cull_mode = 2
specular_mode = 1
albedo_texture = ExtResource("1_8jtmf")
albedo_texture = ExtResource("1_iex1v")
metallic = 0.293814
roughness = 0.64433

View file

@ -1,6 +1,6 @@
[gd_resource type="StandardMaterial3D" load_steps=2 format=3 uid="uid://c2ic02ndhqkod"]
[ext_resource type="Texture2D" uid="uid://03bidmgkyu7x" path="res://models/character_grid.png" id="1_54a4n"]
[ext_resource type="Texture2D" uid="uid://bpbh6yad5us1u" path="res://models/character_grid.png" id="1_54a4n"]
[resource]
resource_name = "Primary"

View file

@ -1,4 +1,4 @@
[gd_scene load_steps=23 format=3 uid="uid://1kr3qqan3trk"]
[gd_scene load_steps=28 format=3 uid="uid://1kr3qqan3trk"]
[ext_resource type="PackedScene" uid="uid://vub54xgk5n0h" path="res://models/character.glb" id="1_mi4co"]
@ -6,9 +6,9 @@
animation = &"Aim"
play_mode = 1
use_custom_timeline = true
timeline_length = 0.6
timeline_length = 0.4
stretch_time_scale = false
start_offset = 0.4
start_offset = 0.0
loop_mode = 0
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_nhlru"]
@ -53,8 +53,7 @@ advance_expression = "get_input_directions().y <= 0.5"
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_c81tj"]
advance_mode = 2
advance_expression = "get_input_directions().y < -0.5
"
advance_expression = "get_input_directions().y < -0.9"
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_r26s5"]
advance_mode = 2
@ -62,7 +61,7 @@ advance_mode = 2
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_4lybd"]
switch_mode = 2
advance_mode = 2
advance_expression = "get_input_directions().y >= -0.5"
advance_expression = "get_input_directions().y >= -0.9"
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_4im1q"]
priority = 2
@ -78,6 +77,7 @@ advance_expression = "get_input_direction() > 0.f"
priority = 2
switch_mode = 2
advance_mode = 2
advance_expression = "get_input_fire()"
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_xnat3"]
reset = false
@ -89,25 +89,51 @@ advance_mode = 2
advance_expression = "get_input_directions().y < -0.5"
[sub_resource type="AnimationNodeStateMachine" id="AnimationNodeStateMachine_7smdg"]
"states/Aim Down/node" = SubResource("AnimationNodeAnimation_ukhqm")
"states/Aim Down/position" = Vector2(486, 196)
"states/Aim Up/node" = SubResource("AnimationNodeAnimation_nhlru")
"states/Aim Up/position" = Vector2(486, 98.5)
states/Aim_Fire/node = SubResource("AnimationNodeAnimation_8rbkq")
states/Aim_Fire/position = Vector2(647.5, 98)
states/Idle/node = SubResource("AnimationNodeAnimation_dqnnp")
states/Idle/position = Vector2(338, 100)
"states/Aim Down [aim]/node" = SubResource("AnimationNodeAnimation_ukhqm")
"states/Aim Down [aim]/position" = Vector2(537, 197.5)
"states/Aim [aim] [turn]/node" = SubResource("AnimationNodeAnimation_nhlru")
"states/Aim [aim] [turn]/position" = Vector2(537, 98)
states/End/position = Vector2(204, 197.5)
"states/Fire [aim]/node" = SubResource("AnimationNodeAnimation_8rbkq")
"states/Fire [aim]/position" = Vector2(752.5, 98)
"states/Idle [turn_animated]/node" = SubResource("AnimationNodeAnimation_dqnnp")
"states/Idle [turn_animated]/position" = Vector2(338, 100)
states/Start/position = Vector2(204, 100)
states/Walk/node = SubResource("AnimationNodeBlendTree_2mbyh")
states/Walk/position = Vector2(338, 197.5)
transitions = ["Idle", "Walk", SubResource("AnimationNodeStateMachineTransition_3mk5o"), "Walk", "Idle", SubResource("AnimationNodeStateMachineTransition_mf4y3"), "Idle", "Aim Up", SubResource("AnimationNodeStateMachineTransition_c81tj"), "Start", "Idle", SubResource("AnimationNodeStateMachineTransition_r26s5"), "Aim Up", "Aim Down", SubResource("AnimationNodeStateMachineTransition_4lybd"), "Aim Down", "Idle", SubResource("AnimationNodeStateMachineTransition_4im1q"), "Aim Down", "Walk", SubResource("AnimationNodeStateMachineTransition_5aafd"), "Aim Up", "Aim_Fire", SubResource("AnimationNodeStateMachineTransition_8f4gl"), "Aim_Fire", "Aim Up", SubResource("AnimationNodeStateMachineTransition_xnat3"), "Walk", "Aim Up", SubResource("AnimationNodeStateMachineTransition_12bos")]
graph_offset = Vector2(-290.049, -113.5)
"states/Walk [turn]/node" = SubResource("AnimationNodeBlendTree_2mbyh")
"states/Walk [turn]/position" = Vector2(338, 197.5)
transitions = ["Idle [turn_animated]", "Walk [turn]", SubResource("AnimationNodeStateMachineTransition_3mk5o"), "Walk [turn]", "Idle [turn_animated]", SubResource("AnimationNodeStateMachineTransition_mf4y3"), "Idle [turn_animated]", "Aim [aim] [turn]", SubResource("AnimationNodeStateMachineTransition_c81tj"), "Start", "Idle [turn_animated]", SubResource("AnimationNodeStateMachineTransition_r26s5"), "Aim [aim] [turn]", "Aim Down [aim]", SubResource("AnimationNodeStateMachineTransition_4lybd"), "Aim Down [aim]", "Idle [turn_animated]", SubResource("AnimationNodeStateMachineTransition_4im1q"), "Aim Down [aim]", "Walk [turn]", SubResource("AnimationNodeStateMachineTransition_5aafd"), "Aim [aim] [turn]", "Fire [aim]", SubResource("AnimationNodeStateMachineTransition_8f4gl"), "Fire [aim]", "Aim [aim] [turn]", SubResource("AnimationNodeStateMachineTransition_xnat3"), "Walk [turn]", "Aim [aim] [turn]", SubResource("AnimationNodeStateMachineTransition_12bos")]
graph_offset = Vector2(-351.759, -7)
[sub_resource type="AnimationNodeBlend2" id="AnimationNodeBlend2_cwpxw"]
filter_enabled = true
filters = ["Character/Skeleton3D:Foot.L", "Character/Skeleton3D:Foot.R", "Character/Skeleton3D:IKTarget.Foot.L", "Character/Skeleton3D:IKTarget.Foot.R", "Character/Skeleton3D:PoleTarget.Foot.L", "Character/Skeleton3D:PoleTarget.Foot.R", "Character/Skeleton3D:hip", "Character/Skeleton3D:lowerleg.L", "Character/Skeleton3D:lowerleg.R", "Character/Skeleton3D:spine.001", "Character/Skeleton3D:upperleg.L", "Character/Skeleton3D:upperleg.R"]
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_ltmcj"]
animation = &"Turn_left"
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_1g6a2"]
animation = &"Turn_right"
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_dgkx8"]
animation = &"RESET"
[sub_resource type="AnimationNodeBlendSpace1D" id="AnimationNodeBlendSpace1D_ajqf0"]
blend_point_0/node = SubResource("AnimationNodeAnimation_ltmcj")
blend_point_0/pos = 1.0
blend_point_1/node = SubResource("AnimationNodeAnimation_1g6a2")
blend_point_1/pos = -1.0
blend_point_2/node = SubResource("AnimationNodeAnimation_dgkx8")
blend_point_2/pos = 0.0
[sub_resource type="AnimationNodeBlendTree" id="AnimationNodeBlendTree_hiswf"]
graph_offset = Vector2(-510.4, 51.9)
graph_offset = Vector2(-203, -3.5)
nodes/Actions/node = SubResource("AnimationNodeStateMachine_7smdg")
nodes/Actions/position = Vector2(20, 140)
node_connections = [&"output", 0, &"Actions"]
nodes/Actions/position = Vector2(-80, 140)
nodes/TurnAnimation/node = SubResource("AnimationNodeBlend2_cwpxw")
nodes/TurnAnimation/position = Vector2(120, 140)
nodes/TurnDirection/node = SubResource("AnimationNodeBlendSpace1D_ajqf0")
nodes/TurnDirection/position = Vector2(-80, 300)
node_connections = [&"TurnAnimation", 0, &"Actions", &"TurnAnimation", 1, &"TurnDirection", &"output", 0, &"TurnAnimation"]
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_ewsvd"]
radius = 0.370388
@ -126,7 +152,7 @@ transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.0337329, 0)
[node name="Skeleton3D" parent="CharacterModel/Character" index="0"]
bones/0/rotation = Quaternion(1.12928e-22, 1, 2.98023e-08, -1.94707e-07)
bones/1/position = Vector3(3.28472e-17, 0.826102, -2.26306e-09)
bones/1/rotation = Quaternion(-0.0189873, -6.3066e-09, -1.08731e-09, 0.99982)
bones/1/rotation = Quaternion(-0.0189874, -6.30661e-09, -1.08732e-09, 0.99982)
bones/2/rotation = Quaternion(0.0262842, 8.66579e-09, 1.56723e-09, 0.999655)
bones/3/rotation = Quaternion(-0.013812, -0.124595, 8.42949e-05, 0.992112)
bones/4/rotation = Quaternion(0.0100466, -3.89644e-10, 6.78268e-10, 0.99995)
@ -203,16 +229,18 @@ bones/51/scale = Vector3(1, 1, 1)
bones/52/rotation = Quaternion(-0.00225666, 0.00306653, -0.000453776, 0.999993)
bones/52/scale = Vector3(1, 1, 1)
bones/53/rotation = Quaternion(0.665461, 0.000165138, -0.00238783, 0.746429)
bones/54/rotation = Quaternion(0.997309, 0.00549227, -0.0715033, -0.015225)
bones/54/rotation = Quaternion(0.997309, 0.00549226, -0.0715033, -0.015225)
bones/54/scale = Vector3(1, 1, 1)
bones/55/rotation = Quaternion(-0.00225666, -0.0030665, 0.000453778, 0.999993)
bones/55/scale = Vector3(1, 1, 1)
bones/56/rotation = Quaternion(0.665461, -0.000165001, 0.00238774, 0.746429)
bones/56/scale = Vector3(1, 1, 1)
bones/57/rotation = Quaternion(-0.707107, 8.33981e-07, 8.33981e-07, 0.707107)
bones/58/rotation = Quaternion(-0.707107, -8.33981e-07, -8.33981e-07, 0.707107)
bones/57/rotation = Quaternion(-2.99921e-13, 0.707107, 0.707107, -2.99921e-13)
bones/58/rotation = Quaternion(2.01446e-13, 0.707107, 0.707107, 2.01446e-13)
bones/59/rotation = Quaternion(-0.707107, 1.25097e-07, 1.25097e-07, 0.707107)
bones/60/rotation = Quaternion(-0.707107, 1.25097e-07, 1.25097e-07, 0.707107)
bones/61/rotation = Quaternion(-0.707107, 1.5189e-07, 1.5189e-07, 0.707107)
bones/62/rotation = Quaternion(-0.707107, 1.5189e-07, 1.5189e-07, 0.707107)
[node name="AnimationTree" type="AnimationTree" parent="CharacterModel"]
unique_name_in_owner = true
@ -221,16 +249,21 @@ root_motion_track = NodePath("Character/Skeleton3D:root")
tree_root = SubResource("AnimationNodeBlendTree_hiswf")
advance_expression_base_node = NodePath("../..")
anim_player = NodePath("../AnimationPlayer")
parameters/Actions/Walk/Forward/blend_amount = 1.0
[node name="Camera" type="Camera3D" parent="."]
unique_name_in_owner = true
transform = Transform3D(-1, -6.25962e-09, -8.71984e-08, -1.4325e-08, 0.995684, 0.0928047, 8.62412e-08, 0.0928047, -0.995684, -0.383042, 1.71014, -0.773267)
fov = 57.0005
far = 100.0
"parameters/Actions/Walk [turn]/Forward/blend_amount" = 1.0
parameters/TurnAnimation/blend_amount = 0
parameters/TurnDirection/blend_position = -1.0
[node name="CollisionShape3D" type="CollisionShape3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0)
shape = SubResource("CapsuleShape3D_ewsvd")
[node name="CameraParent" type="Node3D" parent="."]
unique_name_in_owner = true
top_level = true
[node name="Camera" type="Camera3D" parent="CameraParent"]
transform = Transform3D(-0.99874, 0.00857726, -0.0494361, -1.83936e-08, 0.98528, 0.170948, 0.0501747, 0.170733, -0.984039, -0.510957, 1.68471, -1.00759)
fov = 42.5804
far = 100.0
[editable path="CharacterModel"]

View file

@ -41,13 +41,13 @@ dir_backward={
dir_left={
"deadzone": 0.2,
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":65,"key_label":0,"unicode":97,"location":0,"echo":false,"script":null)
, Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":-1,"axis":0,"axis_value":-1.0,"script":null)
, Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":-1,"axis":2,"axis_value":-1.0,"script":null)
]
}
dir_right={
"deadzone": 0.2,
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":68,"key_label":0,"unicode":100,"location":0,"echo":false,"script":null)
, Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":-1,"axis":0,"axis_value":1.0,"script":null)
, Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":-1,"axis":2,"axis_value":1.0,"script":null)
]
}
look_left={
@ -70,6 +70,12 @@ look_down={
"events": [Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":-1,"axis":3,"axis_value":1.0,"script":null)
]
}
fire={
"deadzone": 0.5,
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":32,"key_label":0,"unicode":32,"location":0,"echo":false,"script":null)
, Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":-1,"button_index":3,"pressure":0.0,"pressed":true,"script":null)
]
}
[physics]