feat: implemented swing_3 impact effects
This commit is contained in:
parent
0c0c3adb15
commit
86c73ddb67
15 changed files with 6362 additions and 1 deletions
BIN
project/assets/animations/player_character/swing_1.res
Normal file
BIN
project/assets/animations/player_character/swing_1.res
Normal file
Binary file not shown.
BIN
project/assets/animations/player_character/swing_2.res
Normal file
BIN
project/assets/animations/player_character/swing_2.res
Normal file
Binary file not shown.
BIN
project/assets/animations/player_character/swing_3.res
Normal file
BIN
project/assets/animations/player_character/swing_3.res
Normal file
Binary file not shown.
BIN
project/assets/decals/impact/impact_albedo.png
Normal file
BIN
project/assets/decals/impact/impact_albedo.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.4 MiB |
34
project/assets/decals/impact/impact_albedo.png.import
Normal file
34
project/assets/decals/impact/impact_albedo.png.import
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://b3cv8dbbgsip7"
|
||||
path="res://.godot/imported/impact_albedo.png-5f7bbc9a80ad0ba0f09cfa0e726127f7.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://assets/decals/impact/impact_albedo.png"
|
||||
dest_files=["res://.godot/imported/impact_albedo.png-5f7bbc9a80ad0ba0f09cfa0e726127f7.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
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=1
|
||||
BIN
project/assets/decals/impact/impact_normal.png
Normal file
BIN
project/assets/decals/impact/impact_normal.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 3.9 MiB |
34
project/assets/decals/impact/impact_normal.png.import
Normal file
34
project/assets/decals/impact/impact_normal.png.import
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://b20tk50rgd1du"
|
||||
path="res://.godot/imported/impact_normal.png-0e4dbfbf91c452df89294c09905c4ddf.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://assets/decals/impact/impact_normal.png"
|
||||
dest_files=["res://.godot/imported/impact_normal.png-0e4dbfbf91c452df89294c09905c4ddf.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
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=1
|
||||
|
|
@ -0,0 +1,31 @@
|
|||
[gd_resource type="StandardMaterial3D" load_steps=5 format=3 uid="uid://cx3sl5hvxpkph"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://o8l4dfrkd3nr" path="res://assets/effects/particle_textures/cloud.tres" id="1_q7rjh"]
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_f4d1b"]
|
||||
offsets = PackedFloat32Array(0.940005, 1)
|
||||
colors = PackedColorArray(1, 1, 1, 1, 1, 1, 1, 0)
|
||||
|
||||
[sub_resource type="GradientTexture2D" id="GradientTexture2D_yiuqf"]
|
||||
gradient = SubResource("Gradient_f4d1b")
|
||||
fill = 1
|
||||
fill_from = Vector2(0.5, 0.5)
|
||||
fill_to = Vector2(0.518528, 0.0264593)
|
||||
|
||||
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_yiuqf"]
|
||||
transparency = 1
|
||||
shading_mode = 0
|
||||
diffuse_mode = 3
|
||||
albedo_color = Color(0, 0, 0, 1)
|
||||
albedo_texture = ExtResource("1_q7rjh")
|
||||
grow_amount = 0.05
|
||||
|
||||
[resource]
|
||||
render_priority = 1
|
||||
next_pass = SubResource("StandardMaterial3D_yiuqf")
|
||||
transparency = 1
|
||||
shading_mode = 0
|
||||
diffuse_mode = 3
|
||||
specular_mode = 1
|
||||
albedo_color = Color(1, 0.28, 0.568, 1)
|
||||
albedo_texture = SubResource("GradientTexture2D_yiuqf")
|
||||
11
project/assets/effects/particle_textures/cloud.tres
Normal file
11
project/assets/effects/particle_textures/cloud.tres
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
[gd_resource type="GradientTexture2D" load_steps=2 format=3 uid="uid://o8l4dfrkd3nr"]
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_f4d1b"]
|
||||
offsets = PackedFloat32Array(0.940005, 1)
|
||||
colors = PackedColorArray(1, 1, 1, 1, 1, 1, 1, 0)
|
||||
|
||||
[resource]
|
||||
gradient = SubResource("Gradient_f4d1b")
|
||||
fill = 1
|
||||
fill_from = Vector2(0.5, 0.5)
|
||||
fill_to = Vector2(0.5, 0)
|
||||
Binary file not shown.
File diff suppressed because it is too large
Load diff
Binary file not shown.
57
project/objects/effects/impact_decal.tscn
Normal file
57
project/objects/effects/impact_decal.tscn
Normal file
|
|
@ -0,0 +1,57 @@
|
|||
[gd_scene load_steps=9 format=3 uid="uid://2fxwkeifrwu3"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://b3cv8dbbgsip7" path="res://assets/decals/impact/impact_albedo.png" id="1_f4d1b"]
|
||||
[ext_resource type="Texture2D" uid="uid://b20tk50rgd1du" path="res://assets/decals/impact/impact_normal.png" id="2_yiuqf"]
|
||||
[ext_resource type="Material" uid="uid://cx3sl5hvxpkph" path="res://assets/effects/particle_materials/explosion_orbs_material.tres" id="3_yiuqf"]
|
||||
|
||||
[sub_resource type="Curve" id="Curve_yiuqf"]
|
||||
_data = [Vector2(0, 0), 0.0, 3.44635, 0, 0, Vector2(0.456585, 1), 0.0, 0.0, 0, 0]
|
||||
point_count = 2
|
||||
|
||||
[sub_resource type="CurveTexture" id="CurveTexture_p1nm6"]
|
||||
curve = SubResource("Curve_yiuqf")
|
||||
|
||||
[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_f4d1b"]
|
||||
direction = Vector3(0, 1, 0)
|
||||
spread = 180.0
|
||||
flatness = 0.8
|
||||
initial_velocity_min = 10.0
|
||||
initial_velocity_max = 15.0
|
||||
gravity = Vector3(0, 0, 0)
|
||||
scale_curve = SubResource("CurveTexture_p1nm6")
|
||||
|
||||
[sub_resource type="QuadMesh" id="QuadMesh_bxu7p"]
|
||||
material = ExtResource("3_yiuqf")
|
||||
size = Vector2(2, 2)
|
||||
|
||||
[sub_resource type="GDScript" id="GDScript_yiuqf"]
|
||||
script/source = "extends GPUParticles3D
|
||||
|
||||
func _ready():
|
||||
self.restart()
|
||||
"
|
||||
|
||||
[node name="ImpactDecal" type="Node3D"]
|
||||
|
||||
[node name="Decal" type="Decal" parent="."]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 2.14612)
|
||||
size = Vector3(4, 1.65991, 4)
|
||||
texture_albedo = ExtResource("1_f4d1b")
|
||||
texture_normal = ExtResource("2_yiuqf")
|
||||
normal_fade = 0.5
|
||||
upper_fade = 1e-05
|
||||
lower_fade = 1e-05
|
||||
cull_mask = 1048570
|
||||
|
||||
[node name="GPUParticles3D" type="GPUParticles3D" parent="."]
|
||||
transform = Transform3D(-4.37114e-08, -1, 0, 1, -4.37114e-08, 0, 0, 0, 1, 0, 0.418153, 2.15406)
|
||||
emitting = false
|
||||
amount = 10
|
||||
lifetime = 0.1
|
||||
one_shot = true
|
||||
explosiveness = 0.9
|
||||
fixed_fps = 15
|
||||
transform_align = 3
|
||||
process_material = SubResource("ParticleProcessMaterial_f4d1b")
|
||||
draw_pass_1 = SubResource("QuadMesh_bxu7p")
|
||||
script = SubResource("GDScript_yiuqf")
|
||||
|
|
@ -1,6 +1,7 @@
|
|||
[gd_scene load_steps=21 format=3 uid="uid://csr23278g4hqe"]
|
||||
[gd_scene load_steps=23 format=3 uid="uid://csr23278g4hqe"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://cj3x6a8gm4ogn" path="res://assets/models/character.blend" id="1_yaurm"]
|
||||
[ext_resource type="PackedScene" uid="uid://2fxwkeifrwu3" path="res://objects/effects/impact_decal.tscn" id="2_1p07c"]
|
||||
|
||||
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_5j0w6"]
|
||||
radius = 0.252441
|
||||
|
|
@ -82,6 +83,21 @@ states/swing_3/position = Vector2(482.905, 176.95)
|
|||
transitions = ["Start", "idle", SubResource("AnimationNodeStateMachineTransition_yaurm"), "swing_1", "swing_2", SubResource("AnimationNodeStateMachineTransition_dj8sy"), "swing_2", "swing_3", SubResource("AnimationNodeStateMachineTransition_vapos"), "swing_3", "ready_idle", SubResource("AnimationNodeStateMachineTransition_0qik6"), "swing_2", "ready_idle", SubResource("AnimationNodeStateMachineTransition_1p07c"), "swing_1", "ready_idle", SubResource("AnimationNodeStateMachineTransition_l4dj5"), "ready_idle", "swing_1", SubResource("AnimationNodeStateMachineTransition_l45uo"), "idle", "ready_idle", SubResource("AnimationNodeStateMachineTransition_7anxi"), "idle", "run", SubResource("AnimationNodeStateMachineTransition_abvwl"), "run", "idle", SubResource("AnimationNodeStateMachineTransition_njhnd"), "ready_idle", "idle", SubResource("AnimationNodeStateMachineTransition_0jr6v")]
|
||||
graph_offset = Vector2(-228.371, 13.6511)
|
||||
|
||||
[sub_resource type="GDScript" id="GDScript_yaurm"]
|
||||
script/source = "extends Node3D
|
||||
|
||||
@export var scene : PackedScene
|
||||
|
||||
func emit():
|
||||
var instance : Node3D = scene.instantiate()
|
||||
instance.position = global_position
|
||||
instance.rotation = global_rotation
|
||||
get_tree().current_scene.add_child(instance)
|
||||
Engine.time_scale = 0.01
|
||||
await get_tree().create_timer(0.1, true, false, true).timeout
|
||||
Engine.time_scale = 1.0
|
||||
"
|
||||
|
||||
[node name="PlayerBody" type="PlayerBody"]
|
||||
|
||||
[node name="PlayerIdleState" type="PlayerIdleState" parent="."]
|
||||
|
|
@ -118,4 +134,8 @@ anim_player = NodePath("../character/AnimationPlayer")
|
|||
|
||||
[node name="character" parent="." instance=ExtResource("1_yaurm")]
|
||||
|
||||
[node name="GroundCracksEmitter" type="Node3D" parent="."]
|
||||
script = SubResource("GDScript_yaurm")
|
||||
scene = ExtResource("2_1p07c")
|
||||
|
||||
[editable path="character"]
|
||||
|
|
|
|||
|
|
@ -8,6 +8,10 @@
|
|||
|
||||
config_version=5
|
||||
|
||||
[animation]
|
||||
|
||||
warnings/check_invalid_track_paths=false
|
||||
|
||||
[application]
|
||||
|
||||
config/name="break_utopia"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue