Improve flash
This commit is contained in:
parent
7614b12076
commit
0fc71532e2
5 changed files with 8 additions and 5 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -13,3 +13,4 @@ data_*/
|
||||||
mono_crash.*.json
|
mono_crash.*.json
|
||||||
|
|
||||||
puki.txt
|
puki.txt
|
||||||
|
export
|
||||||
|
|
@ -83,6 +83,8 @@ cheat_zombie_spawn={
|
||||||
2d_physics/layer_3="Plants Full"
|
2d_physics/layer_3="Plants Full"
|
||||||
2d_physics/layer_4="Zombies LD"
|
2d_physics/layer_4="Zombies LD"
|
||||||
2d_physics/layer_5="Zombies Full"
|
2d_physics/layer_5="Zombies Full"
|
||||||
|
2d_physics/layer_7="FallLine"
|
||||||
|
2d_physics/layer_8="FallParticles"
|
||||||
|
|
||||||
[rendering]
|
[rendering]
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@
|
||||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_63ls2"]
|
[sub_resource type="ShaderMaterial" id="ShaderMaterial_63ls2"]
|
||||||
resource_local_to_scene = true
|
resource_local_to_scene = true
|
||||||
shader = ExtResource("2_srwwe")
|
shader = ExtResource("2_srwwe")
|
||||||
shader_parameter/blend_color = Color(1, 1, 1, 1)
|
shader_parameter/blend_color = Color(0.73, 0.73, 0.73, 1)
|
||||||
shader_parameter/amount = 0.0
|
shader_parameter/amount = 0.0
|
||||||
|
|
||||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_hxyad"]
|
[sub_resource type="RectangleShape2D" id="RectangleShape2D_hxyad"]
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,7 @@ public partial class FlashComponent : CanvasGroup
|
||||||
_tween = CreateTween();
|
_tween = CreateTween();
|
||||||
|
|
||||||
Action<float> action = SetAmount;
|
Action<float> action = SetAmount;
|
||||||
_tween.TweenMethod(Callable.From(action),1.0f,0.0f,_flashDuration);
|
_tween.TweenMethod(Callable.From(action),0.8f,0.0f,_flashDuration);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void SetAmount(float amount)
|
private void SetAmount(float amount)
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ public partial class GameRegistry : Node
|
||||||
public override void _Ready()
|
public override void _Ready()
|
||||||
{
|
{
|
||||||
//Plant init
|
//Plant init
|
||||||
string[] plantFiles = DirAccess.GetFilesAt(PLANT_RESOURCE_PATH);
|
string[] plantFiles = ResourceLoader.ListDirectory(PLANT_RESOURCE_PATH);
|
||||||
|
|
||||||
foreach (var file in plantFiles)
|
foreach (var file in plantFiles)
|
||||||
{
|
{
|
||||||
|
|
@ -26,7 +26,7 @@ public partial class GameRegistry : Node
|
||||||
}
|
}
|
||||||
|
|
||||||
//Zombie init
|
//Zombie init
|
||||||
string[] zombieFiles = DirAccess.GetFilesAt(ZOMBIE_RESOURCE_PATH);
|
string[] zombieFiles = ResourceLoader.ListDirectory(ZOMBIE_RESOURCE_PATH);
|
||||||
|
|
||||||
foreach (var file in zombieFiles)
|
foreach (var file in zombieFiles)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue