improved visuals
|
@ -0,0 +1,24 @@
|
|||
[remap]
|
||||
|
||||
importer="wav"
|
||||
type="AudioStreamWAV"
|
||||
uid="uid://qvthq6tppp63"
|
||||
path="res://.godot/imported/whoosh.wav-ed2d61376c9fa3c90f1bcd8d0d47a04b.sample"
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Assets/Sounds/whoosh.wav"
|
||||
dest_files=["res://.godot/imported/whoosh.wav-ed2d61376c9fa3c90f1bcd8d0d47a04b.sample"]
|
||||
|
||||
[params]
|
||||
|
||||
force/8_bit=false
|
||||
force/mono=false
|
||||
force/max_rate=false
|
||||
force/max_rate_hz=44100
|
||||
edit/trim=false
|
||||
edit/normalize=false
|
||||
edit/loop_mode=0
|
||||
edit/loop_begin=0
|
||||
edit/loop_end=-1
|
||||
compress/mode=0
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 78 B |
|
@ -0,0 +1,34 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://dpepm54hjuyga"
|
||||
path="res://.godot/imported/forsen-hand.png-d22d8449d49935bb2be976828e8a6ea2.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Assets/Sprites/Characters/forsen-hand.png"
|
||||
dest_files=["res://.godot/imported/forsen-hand.png-d22d8449d49935bb2be976828e8a6ea2.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
|
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 2.2 KiB |
|
@ -0,0 +1,25 @@
|
|||
[gd_resource type="ParticleProcessMaterial" load_steps=3 format=3 uid="uid://bat28samf7ukd"]
|
||||
|
||||
[sub_resource type="Curve" id="Curve_jqr7v"]
|
||||
_data = [Vector2(0, 0), 0.0, 2.0, 0, 1, Vector2(0.5, 1), 0.0, 0.0, 0, 0, Vector2(1, 0), -2.0, 0.0, 1, 0]
|
||||
point_count = 3
|
||||
|
||||
[sub_resource type="CurveTexture" id="CurveTexture_s2csc"]
|
||||
curve = SubResource("Curve_jqr7v")
|
||||
|
||||
[resource]
|
||||
emission_shape = 1
|
||||
emission_sphere_radius = 8.0
|
||||
particle_flag_disable_z = true
|
||||
direction = Vector3(0, -1, 0)
|
||||
gravity = Vector3(0, 0, 0)
|
||||
initial_velocity_min = 64.0
|
||||
initial_velocity_max = 128.0
|
||||
orbit_velocity_min = 0.0
|
||||
orbit_velocity_max = 0.0
|
||||
linear_accel_min = -256.0
|
||||
linear_accel_max = -128.0
|
||||
scale_min = 0.01
|
||||
scale_max = 0.02
|
||||
scale_curve = SubResource("CurveTexture_s2csc")
|
||||
attractor_interaction_enabled = false
|
|
@ -0,0 +1,42 @@
|
|||
[gd_resource type="ParticleProcessMaterial" load_steps=7 format=3 uid="uid://x5qcq5muvc3g"]
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_6k7fi"]
|
||||
offsets = PackedFloat32Array(0, 0.540741, 0.592593, 1)
|
||||
colors = PackedColorArray(0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1)
|
||||
|
||||
[sub_resource type="GradientTexture1D" id="GradientTexture1D_1phkb"]
|
||||
gradient = SubResource("Gradient_6k7fi")
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_3tax5"]
|
||||
offsets = PackedFloat32Array(0, 0.533333, 1)
|
||||
colors = PackedColorArray(1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0)
|
||||
|
||||
[sub_resource type="GradientTexture1D" id="GradientTexture1D_13jjx"]
|
||||
gradient = SubResource("Gradient_3tax5")
|
||||
|
||||
[sub_resource type="Curve" id="Curve_0565g"]
|
||||
_data = [Vector2(0, 0.5), 0.0, 5.0, 0, 1, Vector2(0.1, 1), 0.0, 0.0, 0, 0, Vector2(1, 0), -1.11111, 0.0, 1, 0]
|
||||
point_count = 3
|
||||
|
||||
[sub_resource type="CurveTexture" id="CurveTexture_k4txv"]
|
||||
curve = SubResource("Curve_0565g")
|
||||
|
||||
[resource]
|
||||
emission_shape = 2
|
||||
emission_sphere_radius = 32.0
|
||||
particle_flag_disable_z = true
|
||||
direction = Vector3(0, -1, 0)
|
||||
gravity = Vector3(0, 0, 0)
|
||||
initial_velocity_min = 128.0
|
||||
initial_velocity_max = 256.0
|
||||
orbit_velocity_min = 0.0
|
||||
orbit_velocity_max = 0.0
|
||||
tangential_accel_min = -16.0
|
||||
tangential_accel_max = 16.0
|
||||
scale_min = 0.25
|
||||
scale_max = 0.25
|
||||
scale_curve = SubResource("CurveTexture_k4txv")
|
||||
color_ramp = SubResource("GradientTexture1D_13jjx")
|
||||
color_initial_ramp = SubResource("GradientTexture1D_1phkb")
|
||||
turbulence_enabled = true
|
||||
turbulence_noise_scale = 4.0
|
After Width: | Height: | Size: 131 B |
|
@ -0,0 +1,34 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://c1a7lvb4uuwfy"
|
||||
path="res://.godot/imported/circle-16.png-2c9910635b94cf262d735877f73c9d54.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Assets/Sprites/Particles/circle-16.png"
|
||||
dest_files=["res://.godot/imported/circle-16.png-2c9910635b94cf262d735877f73c9d54.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
|
After Width: | Height: | Size: 765 B |
|
@ -0,0 +1,34 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://d75jkoev5v3w"
|
||||
path="res://.godot/imported/circle-64.png-14e0a440e19bf6b7889c28107bfd3189.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Assets/Sprites/Particles/circle-64.png"
|
||||
dest_files=["res://.godot/imported/circle-64.png-14e0a440e19bf6b7889c28107bfd3189.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
|
After Width: | Height: | Size: 78 B |
|
@ -0,0 +1,34 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://b75oak1nd2q6x"
|
||||
path="res://.godot/imported/over-under-bar.png-2dd8e0831ce7b8d0ab833d2ac7ca543b.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Assets/Sprites/UI/over-under-bar.png"
|
||||
dest_files=["res://.godot/imported/over-under-bar.png-2dd8e0831ce7b8d0ab833d2ac7ca543b.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
|
After Width: | Height: | Size: 102 B |
|
@ -0,0 +1,34 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://co7xm7i5f6n51"
|
||||
path="res://.godot/imported/progress-bar.png-0e003ec68d4d1aedbb2c4345d3d47107.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Assets/Sprites/UI/progress-bar.png"
|
||||
dest_files=["res://.godot/imported/progress-bar.png-0e003ec68d4d1aedbb2c4345d3d47107.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
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 785 B |
|
@ -0,0 +1,34 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://cmvh6pc71ir1m"
|
||||
path="res://.godot/imported/sword-swing-large.png-d24bea57b216aba22c9a1cccd93085d2.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://Assets/Sprites/sword-swing-large.png"
|
||||
dest_files=["res://.godot/imported/sword-swing-large.png-d24bea57b216aba22c9a1cccd93085d2.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
|
Before Width: | Height: | Size: 325 B After Width: | Height: | Size: 299 B |
|
@ -0,0 +1,21 @@
|
|||
using Godot;
|
||||
|
||||
namespace SupaLidlGame.BoundingBoxes;
|
||||
|
||||
public partial class CameraBounds : Area2D
|
||||
{
|
||||
public override void _Ready()
|
||||
{
|
||||
BodyEntered += OnBodyEntered;
|
||||
base._Ready();
|
||||
}
|
||||
|
||||
private void OnBodyEntered(Node2D body)
|
||||
{
|
||||
if (body is Characters.Player player)
|
||||
{
|
||||
var camera = player.Camera;
|
||||
//camera.LimitLeft =
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,14 @@
|
|||
using Godot;
|
||||
|
||||
namespace SupaLidlGame.Characters;
|
||||
|
||||
public abstract partial class Boss : Enemy
|
||||
{
|
||||
[Export]
|
||||
public State.NPC.NPCStateMachine BossStateMachine { get; set; }
|
||||
|
||||
public abstract int Intensity { get; }
|
||||
|
||||
[Export]
|
||||
public bool IsActive { get; set; }
|
||||
}
|
|
@ -39,9 +39,12 @@ public partial class Character : CharacterBody2D, IFaction
|
|||
public Vector2 Direction { get; set; } = Vector2.Zero;
|
||||
|
||||
public Vector2 Target { get; set; } = Vector2.Zero;
|
||||
|
||||
[Export]
|
||||
public Texture2D HandTexture { get; set; }
|
||||
|
||||
[Export]
|
||||
public float Health
|
||||
public virtual float Health
|
||||
{
|
||||
get => _health;
|
||||
set
|
||||
|
@ -186,6 +189,13 @@ public partial class Character : CharacterBody2D, IFaction
|
|||
}
|
||||
}
|
||||
|
||||
protected virtual float ReceiveDamage(
|
||||
float damage,
|
||||
Character inflictor,
|
||||
float knockback,
|
||||
Vector2 knockbackDir = default) => damage;
|
||||
|
||||
|
||||
public virtual void OnReceivedDamage(
|
||||
float damage,
|
||||
Character inflictor,
|
||||
|
@ -198,7 +208,7 @@ public partial class Character : CharacterBody2D, IFaction
|
|||
}
|
||||
|
||||
float oldHealth = Health;
|
||||
Health -= damage;
|
||||
Health -= ReceiveDamage(damage, inflictor, knockback, knockbackDir);
|
||||
|
||||
// create damage text
|
||||
var textScene = GD.Load<PackedScene>("res://UI/FloatingText.tscn");
|
||||
|
@ -226,7 +236,7 @@ public partial class Character : CharacterBody2D, IFaction
|
|||
Player plr = inflictor as Player ?? this as Player;
|
||||
if (plr is not null)
|
||||
{
|
||||
plr.Camera.Shake(1, 0.4f);
|
||||
//plr.Camera.Shake(1, 0.4f);
|
||||
}
|
||||
|
||||
if (this.GetNode("HurtSound") is AudioStreamPlayer2D sound)
|
||||
|
|
|
@ -3,12 +3,29 @@ using GodotUtilities;
|
|||
|
||||
namespace SupaLidlGame.Characters;
|
||||
|
||||
public partial class Doc : Enemy
|
||||
public partial class Doc : Boss
|
||||
{
|
||||
[Export]
|
||||
public State.NPC.NPCStateMachine BossStateMachine { get; set; }
|
||||
public AnimationPlayer TelegraphAnimation { get; set; }
|
||||
|
||||
public int Intensity
|
||||
public override float Health
|
||||
{
|
||||
get => base.Health;
|
||||
set
|
||||
{
|
||||
if (IsActive)
|
||||
{
|
||||
base.Health = value;
|
||||
}
|
||||
else
|
||||
{
|
||||
// play opening animation
|
||||
// then become active when it finishes
|
||||
base.Health = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public override int Intensity
|
||||
{
|
||||
get
|
||||
{
|
||||
|
@ -24,17 +41,41 @@ public partial class Doc : Enemy
|
|||
}
|
||||
}
|
||||
|
||||
public Doc()
|
||||
{
|
||||
ShouldMove = false;
|
||||
}
|
||||
|
||||
public override void _Ready()
|
||||
{
|
||||
TelegraphAnimation = GetNode<AnimationPlayer>("Animations/Telegraph");
|
||||
base._Ready();
|
||||
}
|
||||
|
||||
public override void _Process(double delta)
|
||||
{
|
||||
BossStateMachine.Process(delta);
|
||||
if (IsActive)
|
||||
{
|
||||
BossStateMachine.Process(delta);
|
||||
}
|
||||
base._Process(delta);
|
||||
}
|
||||
|
||||
protected override float ReceiveDamage(
|
||||
float damage,
|
||||
Character inflictor,
|
||||
float knockback,
|
||||
Vector2 knockbackDir = default)
|
||||
{
|
||||
if (IsActive)
|
||||
{
|
||||
return base.ReceiveDamage(
|
||||
damage, inflictor, knockback, knockbackDir);
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
public override void OnReceivedDamage(
|
||||
float damage,
|
||||
Character inflictor,
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
[gd_scene load_steps=48 format=3 uid="uid://d2skjvvx6fal0"]
|
||||
[gd_scene load_steps=47 format=3 uid="uid://d2skjvvx6fal0"]
|
||||
|
||||
[ext_resource type="Script" path="res://Characters/Doc.cs" id="2_3elet"]
|
||||
[ext_resource type="Shader" path="res://Shaders/Flash.gdshader" id="2_5jxom"]
|
||||
|
@ -19,7 +19,9 @@
|
|||
[ext_resource type="Script" path="res://State/NPC/Doc/DocChooseAttackState.cs" id="12_45x13"]
|
||||
[ext_resource type="Script" path="res://State/NPC/Doc/DocUnwantedFrequencyState.cs" id="12_d51jv"]
|
||||
[ext_resource type="PackedScene" uid="uid://1y5r6sklwgrp" path="res://Entities/UnwantedFrequency.tscn" id="13_lpj21"]
|
||||
[ext_resource type="Script" path="res://Utils/AnimationManager.cs" id="16_bsvls"]
|
||||
[ext_resource type="Texture2D" uid="uid://bd8l8kafb42dt" path="res://Assets/Sprites/Particles/circle.png" id="16_x277j"]
|
||||
[ext_resource type="Material" uid="uid://bat28samf7ukd" path="res://Assets/Sprites/Particles/NPCDamageProcessMaterial.tres" id="17_iomdx"]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_7n7iy"]
|
||||
resource_local_to_scene = true
|
||||
|
@ -121,6 +123,18 @@ tracks/2/keys = {
|
|||
"update": 0,
|
||||
"values": [Vector2(1, 1)]
|
||||
}
|
||||
tracks/3/type = "value"
|
||||
tracks/3/imported = false
|
||||
tracks/3/enabled = true
|
||||
tracks/3/path = NodePath("../Sprite:modulate")
|
||||
tracks/3/interp = 1
|
||||
tracks/3/loop_wrap = true
|
||||
tracks/3/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 0,
|
||||
"values": [Color(1, 1, 1, 1)]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_7oukw"]
|
||||
resource_name = "enter_in"
|
||||
|
@ -149,6 +163,30 @@ tracks/1/keys = {
|
|||
"update": 0,
|
||||
"values": [Color(1, 1, 1, 0), Color(1, 1, 1, 0.5)]
|
||||
}
|
||||
tracks/2/type = "value"
|
||||
tracks/2/imported = false
|
||||
tracks/2/enabled = true
|
||||
tracks/2/path = NodePath("../Sprite:frame")
|
||||
tracks/2/interp = 1
|
||||
tracks/2/loop_wrap = true
|
||||
tracks/2/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [0]
|
||||
}
|
||||
tracks/3/type = "value"
|
||||
tracks/3/imported = false
|
||||
tracks/3/enabled = true
|
||||
tracks/3/path = NodePath("../Effects/UnwantedFrequenciesParticles:emitting")
|
||||
tracks/3/interp = 1
|
||||
tracks/3/loop_wrap = true
|
||||
tracks/3/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [false]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_j3s0y"]
|
||||
resource_name = "exit_out"
|
||||
|
@ -177,6 +215,30 @@ tracks/1/keys = {
|
|||
"update": 0,
|
||||
"values": [Color(1, 1, 1, 0.5), Color(1, 1, 1, 0)]
|
||||
}
|
||||
tracks/2/type = "value"
|
||||
tracks/2/imported = false
|
||||
tracks/2/enabled = true
|
||||
tracks/2/path = NodePath("../Sprite:frame")
|
||||
tracks/2/interp = 1
|
||||
tracks/2/loop_wrap = true
|
||||
tracks/2/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [0]
|
||||
}
|
||||
tracks/3/type = "value"
|
||||
tracks/3/imported = false
|
||||
tracks/3/enabled = true
|
||||
tracks/3/path = NodePath("../Effects/UnwantedFrequenciesParticles:emitting")
|
||||
tracks/3/interp = 1
|
||||
tracks/3/loop_wrap = true
|
||||
tracks/3/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [false]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_8dhub"]
|
||||
resource_name = "shungite_spike"
|
||||
|
@ -207,7 +269,6 @@ tracks/1/keys = {
|
|||
|
||||
[sub_resource type="Animation" id="Animation_qggcf"]
|
||||
resource_name = "unwanted_frequencies"
|
||||
length = 3.0
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
|
@ -215,7 +276,7 @@ tracks/0/path = NodePath("../Effects/UnwantedFrequenciesParticles:emitting")
|
|||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0, 3),
|
||||
"times": PackedFloat32Array(0, 1),
|
||||
"transitions": PackedFloat32Array(1, 1),
|
||||
"update": 1,
|
||||
"values": [true, false]
|
||||
|
@ -227,10 +288,10 @@ tracks/1/path = NodePath("../Sprite:frame")
|
|||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1, 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 1.8, 1.9, 2, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9),
|
||||
"transitions": PackedFloat32Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1),
|
||||
"times": PackedFloat32Array(0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8),
|
||||
"transitions": PackedFloat32Array(1, 1, 1, 1, 1, 1, 1, 1, 1),
|
||||
"update": 1,
|
||||
"values": [8, 9, 10, 11, 12, 13, 14, 8, 9, 10, 11, 12, 13, 14, 8, 9, 10, 11, 12, 13, 14, 9, 10, 11, 12, 13, 14, 8, 9, 10]
|
||||
"values": [8, 9, 10, 11, 12, 13, 14, 8, 9]
|
||||
}
|
||||
tracks/2/type = "value"
|
||||
tracks/2/imported = false
|
||||
|
@ -268,6 +329,18 @@ tracks/0/keys = {
|
|||
"update": 0,
|
||||
"values": [0.0]
|
||||
}
|
||||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("Effects/HurtParticles:emitting")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [false]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_dxevc"]
|
||||
resource_name = "hurt"
|
||||
|
@ -284,6 +357,18 @@ tracks/0/keys = {
|
|||
"update": 0,
|
||||
"values": [0.0, 1.0, 0.0, 1.0, 0.0, 1.0, 0.0]
|
||||
}
|
||||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("Effects/HurtParticles:emitting")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0, 0.1),
|
||||
"transitions": PackedFloat32Array(1, 1),
|
||||
"update": 1,
|
||||
"values": [true, false]
|
||||
}
|
||||
|
||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_xe5eq"]
|
||||
_data = {
|
||||
|
@ -330,32 +415,11 @@ color_initial_ramp = SubResource("GradientTexture1D_5606i")
|
|||
|
||||
[sub_resource type="CanvasTexture" id="CanvasTexture_hs7xn"]
|
||||
|
||||
[sub_resource type="Curve" id="Curve_jqr7v"]
|
||||
_data = [Vector2(0, 0), 0.0, 2.0, 0, 1, Vector2(0.5, 1), 0.0, 0.0, 0, 0, Vector2(1, 0), -2.0, 0.0, 1, 0]
|
||||
point_count = 3
|
||||
|
||||
[sub_resource type="CurveTexture" id="CurveTexture_s2csc"]
|
||||
curve = SubResource("Curve_jqr7v")
|
||||
|
||||
[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_wkgo8"]
|
||||
emission_shape = 1
|
||||
emission_sphere_radius = 8.0
|
||||
particle_flag_disable_z = true
|
||||
direction = Vector3(0, -1, 0)
|
||||
gravity = Vector3(0, 0, 0)
|
||||
initial_velocity_min = 20.0
|
||||
initial_velocity_max = 30.0
|
||||
orbit_velocity_min = 0.0
|
||||
orbit_velocity_max = 0.0
|
||||
scale_min = 0.01
|
||||
scale_max = 0.01
|
||||
scale_curve = SubResource("CurveTexture_s2csc")
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_uict5"]
|
||||
size = Vector2(16, 8)
|
||||
size = Vector2(11, 5)
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_8lxmf"]
|
||||
size = Vector2(16, 18)
|
||||
size = Vector2(16, 19)
|
||||
|
||||
[node name="Doc" type="CharacterBody2D" node_paths=PackedStringArray("BossStateMachine", "Sprite", "Inventory", "StateMachine", "Hurtbox")]
|
||||
y_sort_enabled = true
|
||||
|
@ -370,7 +434,6 @@ Sprite = NodePath("Sprite")
|
|||
Inventory = NodePath("Inventory")
|
||||
StateMachine = NodePath("StateMachine")
|
||||
Hurtbox = NodePath("Hurtbox")
|
||||
Faction = 2
|
||||
|
||||
[node name="StateMachine" type="Node" parent="." node_paths=PackedStringArray("InitialState", "Character")]
|
||||
script = ExtResource("3_t5jjc")
|
||||
|
@ -439,6 +502,7 @@ TelegraphState = NodePath("../Telegraph")
|
|||
NPC = NodePath("../..")
|
||||
|
||||
[node name="Animations" type="Node" parent="."]
|
||||
script = ExtResource("16_bsvls")
|
||||
|
||||
[node name="Movement" type="AnimationPlayer" parent="Animations"]
|
||||
libraries = {
|
||||
|
@ -459,7 +523,6 @@ libraries = {
|
|||
[node name="Effects" type="Node2D" parent="."]
|
||||
|
||||
[node name="UnwantedFrequenciesParticles" type="GPUParticles2D" parent="Effects"]
|
||||
position = Vector2(0, 8)
|
||||
emitting = false
|
||||
process_material = SubResource("ParticleProcessMaterial_s1tqp")
|
||||
texture = SubResource("CanvasTexture_hs7xn")
|
||||
|
@ -468,33 +531,31 @@ trail_enabled = true
|
|||
trail_sections = 4
|
||||
|
||||
[node name="HurtParticles" type="GPUParticles2D" parent="Effects"]
|
||||
position = Vector2(0, -8)
|
||||
emitting = false
|
||||
process_material = SubResource("ParticleProcessMaterial_wkgo8")
|
||||
process_material = ExtResource("17_iomdx")
|
||||
texture = ExtResource("16_x277j")
|
||||
lifetime = 0.4
|
||||
one_shot = true
|
||||
explosiveness = 1.0
|
||||
|
||||
[node name="Sprite" type="Sprite2D" parent="."]
|
||||
modulate = Color(1, 1, 1, 0.08)
|
||||
y_sort_enabled = true
|
||||
use_parent_material = true
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("3_rs44f")
|
||||
offset = Vector2(0, 4)
|
||||
offset = Vector2(0, -8)
|
||||
hframes = 16
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
visible = false
|
||||
position = Vector2(0, 4)
|
||||
position = Vector2(-0.5, -1.5)
|
||||
shape = SubResource("RectangleShape2D_uict5")
|
||||
|
||||
[node name="Hurtbox" parent="." instance=ExtResource("7_tnve0")]
|
||||
visible = false
|
||||
position = Vector2(0, -4)
|
||||
Faction = 2
|
||||
|
||||
[node name="CollisionShape2D" parent="Hurtbox" index="0"]
|
||||
position = Vector2(0, 4)
|
||||
position = Vector2(0, -3.5)
|
||||
shape = SubResource("RectangleShape2D_8lxmf")
|
||||
|
||||
[node name="Inventory" type="Node2D" parent="."]
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
[gd_scene load_steps=57 format=3 uid="uid://b2254pup8k161"]
|
||||
[gd_scene load_steps=52 format=3 uid="uid://b2254pup8k161"]
|
||||
|
||||
[ext_resource type="Script" path="res://Characters/Player.cs" id="1_flygr"]
|
||||
[ext_resource type="Shader" path="res://Shaders/Flash.gdshader" id="2_ngsgt"]
|
||||
|
@ -11,7 +11,8 @@
|
|||
[ext_resource type="Script" path="res://Utils/AnimationManager.cs" id="7_sdgvb"]
|
||||
[ext_resource type="Script" path="res://Items/Inventory.cs" id="7_xyenu"]
|
||||
[ext_resource type="Script" path="res://State/Character/PlayerRollState.cs" id="8_fy0v5"]
|
||||
[ext_resource type="Texture2D" uid="uid://bd8l8kafb42dt" path="res://Assets/Sprites/Particles/circle.png" id="8_ohe3r"]
|
||||
[ext_resource type="Material" uid="uid://x5qcq5muvc3g" path="res://Assets/Sprites/Particles/PlayerDamageProcessMaterial.tres" id="8_yf112"]
|
||||
[ext_resource type="Texture2D" uid="uid://c1a7lvb4uuwfy" path="res://Assets/Sprites/Particles/circle-16.png" id="9_7gumm"]
|
||||
[ext_resource type="PackedScene" uid="uid://cjgxyhgcyvsv7" path="res://BoundingBoxes/Hurtbox.tscn" id="9_avyu4"]
|
||||
[ext_resource type="AudioStream" uid="uid://bkeyg8weaqnuu" path="res://Assets/Sounds/splat-player.ogg" id="12_vvem5"]
|
||||
[ext_resource type="Script" path="res://BoundingBoxes/InteractionRay.cs" id="13_hs3u1"]
|
||||
|
@ -28,7 +29,7 @@ length = 0.001
|
|||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("../Sprites/Character:frame")
|
||||
tracks/0/path = NodePath("../Sprites/Node2D/Character:frame")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
|
@ -40,7 +41,7 @@ tracks/0/keys = {
|
|||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("../Sprites/Character:rotation")
|
||||
tracks/1/path = NodePath("../Sprites/Node2D/Character:rotation")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
|
@ -57,7 +58,7 @@ loop_mode = 1
|
|||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("../Sprites/Character:frame")
|
||||
tracks/0/path = NodePath("../Sprites/Node2D/Character:frame")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
|
@ -74,7 +75,7 @@ loop_mode = 1
|
|||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("../Sprites/Character:frame")
|
||||
tracks/0/path = NodePath("../Sprites/Node2D/Character:frame")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
|
@ -91,7 +92,7 @@ step = 0.05
|
|||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("../Sprites/Character:rotation")
|
||||
tracks/0/path = NodePath("../Sprites/Node2D/Character:rotation")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
|
@ -107,7 +108,7 @@ length = 0.2
|
|||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("../Sprites/Character:frame")
|
||||
tracks/0/path = NodePath("../Sprites/Node2D/Character:frame")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
|
@ -131,30 +132,30 @@ length = 0.001
|
|||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("../Sprites/Character:frame")
|
||||
tracks/0/path = NodePath("../Sprites/Node2D/Character:frame")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [12]
|
||||
"values": [0]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_3w3u1"]
|
||||
resource_name = "sword"
|
||||
length = 0.2
|
||||
length = 0.3
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("../Sprites/Character:frame")
|
||||
tracks/0/path = NodePath("../Sprites/Node2D/Character:frame")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0, 0.1, 0.2),
|
||||
"transitions": PackedFloat32Array(1, 1, 1),
|
||||
"update": 1,
|
||||
"values": [12, 13, 0]
|
||||
"values": [12, 13, 14]
|
||||
}
|
||||
|
||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_73mj7"]
|
||||
|
@ -180,7 +181,7 @@ tracks/0/keys = {
|
|||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("Sprites/Character:frame")
|
||||
tracks/1/path = NodePath("Sprites/Node2D/Character:frame")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
|
@ -221,7 +222,7 @@ tracks/0/keys = {
|
|||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("Sprites/Character:frame")
|
||||
tracks/1/path = NodePath("Sprites/Node2D/Character:frame")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
|
@ -242,6 +243,20 @@ tracks/2/keys = {
|
|||
"update": 1,
|
||||
"values": [true, false]
|
||||
}
|
||||
tracks/3/type = "method"
|
||||
tracks/3/imported = false
|
||||
tracks/3/enabled = true
|
||||
tracks/3/path = NodePath("Effects/HurtParticles")
|
||||
tracks/3/interp = 1
|
||||
tracks/3/loop_wrap = true
|
||||
tracks/3/keys = {
|
||||
"times": PackedFloat32Array(0.2),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"values": [{
|
||||
"args": [],
|
||||
"method": &"restart"
|
||||
}]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_pjey7"]
|
||||
resource_name = "hurt_flash"
|
||||
|
@ -321,48 +336,21 @@ graph_offset = Vector2(-335.315, -63.5708)
|
|||
|
||||
[sub_resource type="AnimationNodeStateMachinePlayback" id="AnimationNodeStateMachinePlayback_jln87"]
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_6k7fi"]
|
||||
offsets = PackedFloat32Array(0, 0.540741, 0.592593, 1)
|
||||
colors = PackedColorArray(0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1)
|
||||
|
||||
[sub_resource type="GradientTexture1D" id="GradientTexture1D_1phkb"]
|
||||
gradient = SubResource("Gradient_6k7fi")
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_3tax5"]
|
||||
offsets = PackedFloat32Array(0, 0.533333, 1)
|
||||
colors = PackedColorArray(1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0)
|
||||
|
||||
[sub_resource type="GradientTexture1D" id="GradientTexture1D_13jjx"]
|
||||
gradient = SubResource("Gradient_3tax5")
|
||||
|
||||
[sub_resource type="Curve" id="Curve_0565g"]
|
||||
_data = [Vector2(0, 0.5), 0.0, 5.0, 0, 1, Vector2(0.1, 1), 0.0, 0.0, 0, 0, Vector2(1, 0), -1.11111, 0.0, 1, 0]
|
||||
point_count = 3
|
||||
|
||||
[sub_resource type="CurveTexture" id="CurveTexture_k4txv"]
|
||||
curve = SubResource("Curve_0565g")
|
||||
|
||||
[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_humq0"]
|
||||
emission_shape = 2
|
||||
emission_sphere_radius = 32.0
|
||||
[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_852jj"]
|
||||
particle_flag_disable_z = true
|
||||
direction = Vector3(0, -1, 0)
|
||||
spread = 180.0
|
||||
gravity = Vector3(0, 0, 0)
|
||||
initial_velocity_min = 128.0
|
||||
initial_velocity_max = 256.0
|
||||
initial_velocity_min = 8.0
|
||||
initial_velocity_max = 16.0
|
||||
orbit_velocity_min = 0.0
|
||||
orbit_velocity_max = 0.0
|
||||
tangential_accel_min = -8.0
|
||||
tangential_accel_max = -4.0
|
||||
scale_min = 0.01
|
||||
scale_max = 0.01
|
||||
scale_curve = SubResource("CurveTexture_k4txv")
|
||||
color_ramp = SubResource("GradientTexture1D_13jjx")
|
||||
color_initial_ramp = SubResource("GradientTexture1D_1phkb")
|
||||
turbulence_enabled = true
|
||||
turbulence_noise_scale = 4.0
|
||||
linear_accel_min = -32.0
|
||||
linear_accel_max = -16.0
|
||||
scale_min = 0.1
|
||||
scale_max = 0.1
|
||||
|
||||
[sub_resource type="CanvasTexture" id="CanvasTexture_pited"]
|
||||
diffuse_texture = ExtResource("9_7gumm")
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_bfqew"]
|
||||
size = Vector2(12, 8)
|
||||
|
@ -377,14 +365,13 @@ size = Vector2(8, 8)
|
|||
y_sort_enabled = true
|
||||
texture_filter = 3
|
||||
material = SubResource("ShaderMaterial_h78y7")
|
||||
position = Vector2(0, -8)
|
||||
collision_layer = 6
|
||||
collision_mask = 17
|
||||
script = ExtResource("1_flygr")
|
||||
Camera = NodePath("Camera2D")
|
||||
DirectionMarker = NodePath("Direction2D")
|
||||
Speed = 80.0
|
||||
Sprite = NodePath("Sprites/Character")
|
||||
Sprite = NodePath("Sprites/Node2D/Character")
|
||||
Inventory = NodePath("Inventory")
|
||||
StateMachine = NodePath("StateMachine")
|
||||
Hurtbox = NodePath("Hurtbox")
|
||||
|
@ -441,21 +428,31 @@ parameters/conditions/roll = false
|
|||
|
||||
[node name="Effects" type="Node2D" parent="."]
|
||||
|
||||
[node name="DeathParticles" type="GPUParticles2D" parent="Effects"]
|
||||
[node name="RollParticles" type="GPUParticles2D" parent="Effects"]
|
||||
emitting = false
|
||||
amount = 16
|
||||
process_material = SubResource("ParticleProcessMaterial_humq0")
|
||||
process_material = SubResource("ParticleProcessMaterial_852jj")
|
||||
texture = ExtResource("9_7gumm")
|
||||
lifetime = 0.8
|
||||
|
||||
[node name="DeathParticles" type="GPUParticles2D" parent="Effects"]
|
||||
emitting = false
|
||||
amount = 32
|
||||
process_material = ExtResource("8_yf112")
|
||||
texture = SubResource("CanvasTexture_pited")
|
||||
one_shot = true
|
||||
lifetime = 2.0
|
||||
preprocess = 0.1
|
||||
explosiveness = 0.9
|
||||
|
||||
[node name="HurtParticles" type="GPUParticles2D" parent="Effects"]
|
||||
emitting = false
|
||||
amount = 32
|
||||
process_material = SubResource("ParticleProcessMaterial_humq0")
|
||||
texture = ExtResource("8_ohe3r")
|
||||
process_material = ExtResource("8_yf112")
|
||||
texture = ExtResource("9_7gumm")
|
||||
lifetime = 1.5
|
||||
one_shot = true
|
||||
explosiveness = 1.0
|
||||
preprocess = 0.1
|
||||
explosiveness = 0.9
|
||||
|
||||
[node name="Camera2D" parent="." instance=ExtResource("4_ym125")]
|
||||
limit_left = -256
|
||||
|
@ -465,17 +462,21 @@ limit_bottom = 256
|
|||
position_smoothing_speed = 8.0
|
||||
|
||||
[node name="Sprites" type="Node2D" parent="."]
|
||||
use_parent_material = true
|
||||
|
||||
[node name="Character" type="Sprite2D" parent="Sprites"]
|
||||
y_sort_enabled = true
|
||||
use_parent_material = true
|
||||
rotation = 6.28319
|
||||
|
||||
[node name="Node2D" type="Node2D" parent="Sprites"]
|
||||
|
||||
[node name="Character" type="Sprite2D" parent="Sprites/Node2D"]
|
||||
use_parent_material = true
|
||||
position = Vector2(0, -8)
|
||||
texture = ExtResource("4_5vird")
|
||||
offset = Vector2(0, -4)
|
||||
hframes = 23
|
||||
hframes = 24
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
position = Vector2(0, 4)
|
||||
position = Vector2(0, -4)
|
||||
shape = SubResource("RectangleShape2D_bfqew")
|
||||
|
||||
[node name="Debug" type="Control" parent="."]
|
||||
|
@ -494,6 +495,7 @@ label_settings = SubResource("LabelSettings_q5h1n")
|
|||
horizontal_alignment = 1
|
||||
|
||||
[node name="Inventory" type="Node2D" parent="."]
|
||||
position = Vector2(0, -4)
|
||||
script = ExtResource("7_xyenu")
|
||||
InventoryMap = {
|
||||
"equip_1": 0,
|
||||
|
@ -504,10 +506,12 @@ InventoryMap = {
|
|||
visible = false
|
||||
|
||||
[node name="Hurtbox" parent="." node_paths=PackedStringArray("InvincibilityTimer") instance=ExtResource("9_avyu4")]
|
||||
visible = false
|
||||
InvincibilityTimer = NodePath("Timer")
|
||||
Faction = 1
|
||||
|
||||
[node name="CollisionShape2D" parent="Hurtbox" index="0"]
|
||||
visible = false
|
||||
position = Vector2(0, 4)
|
||||
shape = SubResource("RectangleShape2D_cjk6b")
|
||||
|
||||
|
@ -515,22 +519,27 @@ shape = SubResource("RectangleShape2D_cjk6b")
|
|||
one_shot = true
|
||||
|
||||
[node name="HurtSound" type="AudioStreamPlayer2D" parent="."]
|
||||
visible = false
|
||||
stream = ExtResource("12_vvem5")
|
||||
max_distance = 64.0
|
||||
|
||||
[node name="AudioListener2D" type="AudioListener2D" parent="."]
|
||||
visible = false
|
||||
current = true
|
||||
|
||||
[node name="Direction2D" type="Marker2D" parent="."]
|
||||
visible = false
|
||||
position = Vector2(0, 6)
|
||||
|
||||
[node name="InteractionRay" type="RayCast2D" parent="Direction2D"]
|
||||
visible = false
|
||||
target_position = Vector2(16, 0)
|
||||
collision_mask = 64
|
||||
collide_with_areas = true
|
||||
script = ExtResource("13_hs3u1")
|
||||
|
||||
[node name="PointLight2D" type="PointLight2D" parent="."]
|
||||
visible = false
|
||||
blend_mode = 2
|
||||
shadow_enabled = true
|
||||
shadow_filter = 2
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
[gd_scene load_steps=16 format=3 uid="uid://ceadk7pam7vab"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://cyldr0ck3yfrp" path="res://Assets/Sprites/Misc/torch-lamp.png" id="1_dlkl0"]
|
||||
[ext_resource type="Texture2D" uid="uid://b8ann6yb8qox4" path="res://Assets/Sprites/Particles/light-pixel.png" id="2_yuj6j"]
|
||||
[ext_resource type="Texture2D" uid="uid://coarr28adgo1u" path="res://Assets/Sprites/Particles/point-light.png" id="2_0xpf8"]
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_ikvnd"]
|
||||
atlas = ExtResource("1_dlkl0")
|
||||
|
@ -107,9 +107,9 @@ frame_progress = 0.743234
|
|||
offset = Vector2(0, -12)
|
||||
|
||||
[node name="PointLight2D" type="PointLight2D" parent="."]
|
||||
color = Color(1, 0.827451, 0.619608, 1)
|
||||
color = Color(1, 0.803922, 0.698039, 1)
|
||||
energy = 1.2
|
||||
blend_mode = 2
|
||||
shadow_enabled = true
|
||||
shadow_filter_smooth = 3.0
|
||||
texture = ExtResource("2_yuj6j")
|
||||
offset = Vector2(0, 2)
|
||||
texture = ExtResource("2_0xpf8")
|
||||
texture_scale = 0.25
|
||||
|
|
|
@ -1,10 +1,9 @@
|
|||
[gd_scene load_steps=20 format=3 uid="uid://1y5r6sklwgrp"]
|
||||
[gd_scene load_steps=19 format=3 uid="uid://1y5r6sklwgrp"]
|
||||
|
||||
[ext_resource type="Script" path="res://Entities/UnwantedFrequency.cs" id="1_6sbe0"]
|
||||
[ext_resource type="PackedScene" uid="uid://du5vhccg75nrq" path="res://BoundingBoxes/Hitbox.tscn" id="2_gxtvd"]
|
||||
[ext_resource type="PackedScene" uid="uid://cojxmcin13ihm" path="res://Utils/Trail.tscn" id="3_67uhs"]
|
||||
[ext_resource type="AudioStream" uid="uid://cn2wop7rfxku8" path="res://Assets/Sounds/karabast.mp3" id="4_pbgsi"]
|
||||
[ext_resource type="Texture2D" uid="uid://d1ukste16yq6v" path="res://Assets/Sprites/Particles/player-light.png" id="5_d8kx8"]
|
||||
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_30y8q"]
|
||||
size = Vector2(8, 8)
|
||||
|
@ -166,9 +165,4 @@ libraries = {
|
|||
"": SubResource("AnimationLibrary_v8fdt")
|
||||
}
|
||||
|
||||
[node name="PointLight2D" type="PointLight2D" parent="."]
|
||||
energy = 1.2
|
||||
blend_mode = 2
|
||||
texture = ExtResource("5_d8kx8")
|
||||
|
||||
[editable path="Hitbox"]
|
||||
|
|
|
@ -53,6 +53,9 @@ public abstract partial class Weapon : Item
|
|||
[Export]
|
||||
public float MaxDistanceHint { get; set; }
|
||||
|
||||
[Export]
|
||||
public Sprite2D HandAnchor { get; set; }
|
||||
|
||||
public virtual bool IsParryable { get; protected set; } = false;
|
||||
|
||||
public bool IsParried { get; set; }
|
||||
|
@ -70,6 +73,12 @@ public abstract partial class Weapon : Item
|
|||
Visible = true;
|
||||
}
|
||||
Character = character;
|
||||
|
||||
// set the hand textures to the character's
|
||||
if (HandAnchor is not null && character.HandTexture is not null)
|
||||
{
|
||||
HandAnchor.Texture = character.HandTexture;
|
||||
}
|
||||
}
|
||||
|
||||
public override void Unequip(Character character)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
[gd_scene load_steps=35 format=3 uid="uid://dvqap2uhcah63"]
|
||||
[gd_scene load_steps=36 format=3 uid="uid://dvqap2uhcah63"]
|
||||
|
||||
[ext_resource type="Script" path="res://Items/Weapons/Sword.cs" id="1_mlo73"]
|
||||
[ext_resource type="Script" path="res://State/Weapon/WeaponStateMachine.cs" id="2_vwirq"]
|
||||
|
@ -8,8 +8,9 @@
|
|||
[ext_resource type="Script" path="res://State/Weapon/SwordAnticipateState.cs" id="4_j3cud"]
|
||||
[ext_resource type="PackedScene" uid="uid://cojxmcin13ihm" path="res://Utils/Trail.tscn" id="4_pt6lq"]
|
||||
[ext_resource type="Script" path="res://State/Weapon/SwordAttackState.cs" id="5_hmisb"]
|
||||
[ext_resource type="Texture2D" uid="uid://do1bui3bblkk7" path="res://Assets/Sprites/sword-swing.png" id="5_pywek"]
|
||||
[ext_resource type="AudioStream" uid="uid://c4n7ioxpukdwi" path="res://Assets/Sounds/parry.wav" id="6_8nxjm"]
|
||||
[ext_resource type="Texture2D" uid="uid://cmvh6pc71ir1m" path="res://Assets/Sprites/sword-swing-large.png" id="10_672jv"]
|
||||
[ext_resource type="AudioStream" uid="uid://qvthq6tppp63" path="res://Assets/Sounds/whoosh.wav" id="10_mfnl7"]
|
||||
|
||||
[sub_resource type="Environment" id="Environment_72txp"]
|
||||
background_mode = 3
|
||||
|
@ -174,7 +175,7 @@ tracks/1/path = NodePath("SwingSprite:frame")
|
|||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0.1, 0.2, 0.4),
|
||||
"times": PackedFloat32Array(0.1, 0.3, 0.35),
|
||||
"transitions": PackedFloat32Array(1, 1, 1),
|
||||
"update": 1,
|
||||
"values": [1, 2, 0]
|
||||
|
@ -214,6 +215,20 @@ tracks/4/keys = {
|
|||
"transitions": PackedFloat32Array(),
|
||||
"values": []
|
||||
}
|
||||
tracks/5/type = "method"
|
||||
tracks/5/imported = false
|
||||
tracks/5/enabled = true
|
||||
tracks/5/path = NodePath("SwingSound")
|
||||
tracks/5/interp = 1
|
||||
tracks/5/loop_wrap = true
|
||||
tracks/5/keys = {
|
||||
"times": PackedFloat32Array(0.1),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"values": [{
|
||||
"args": [0.0],
|
||||
"method": &"play"
|
||||
}]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_pclfs"]
|
||||
resource_name = "attack_alternate"
|
||||
|
@ -237,10 +252,10 @@ tracks/1/path = NodePath("SwingSprite:frame")
|
|||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0.1, 0.2, 0.4),
|
||||
"times": PackedFloat32Array(0.1, 0.3, 0.35),
|
||||
"transitions": PackedFloat32Array(1, 1, 1),
|
||||
"update": 1,
|
||||
"values": [1, 3, 0]
|
||||
"values": [3, 4, 0]
|
||||
}
|
||||
tracks/2/type = "value"
|
||||
tracks/2/imported = false
|
||||
|
@ -340,11 +355,10 @@ graph_offset = Vector2(0, -104.073)
|
|||
|
||||
[sub_resource type="AnimationNodeStateMachinePlayback" id="AnimationNodeStateMachinePlayback_o5g2u"]
|
||||
|
||||
[sub_resource type="CapsuleShape2D" id="CapsuleShape2D_ic623"]
|
||||
radius = 20.0
|
||||
height = 48.0
|
||||
[sub_resource type="ConvexPolygonShape2D" id="ConvexPolygonShape2D_fcgvv"]
|
||||
points = PackedVector2Array(0, 0, -21.213, 21.213, -30, 0, -21.213, -21.213, 0, -30, 21.213, -21.213, 30, 0, 21.213, 21.213, 0, 0)
|
||||
|
||||
[node name="Sword" type="Node2D" node_paths=PackedStringArray("Hitbox", "AnimationPlayer", "AnimationTree", "ParryParticles", "StateMachine", "Anchor")]
|
||||
[node name="Sword" type="Node2D" node_paths=PackedStringArray("Hitbox", "AnimationPlayer", "AnimationTree", "ParryParticles", "StateMachine", "Anchor", "HandAnchor")]
|
||||
y_sort_enabled = true
|
||||
texture_filter = 3
|
||||
script = ExtResource("1_mlo73")
|
||||
|
@ -361,6 +375,7 @@ Damage = 20.0
|
|||
UseTime = 0.55
|
||||
Knockback = 64.0
|
||||
ShouldHideIdle = true
|
||||
HandAnchor = NodePath("Anchor/Node2D/Sprite2D/Hand")
|
||||
|
||||
[node name="State" type="Node" parent="." node_paths=PackedStringArray("InitialState")]
|
||||
script = ExtResource("2_vwirq")
|
||||
|
@ -422,6 +437,10 @@ initial_velocity_min = 8.0
|
|||
initial_velocity_max = 64.0
|
||||
color_ramp = SubResource("Gradient_jjxq2")
|
||||
|
||||
[node name="Hand" type="Sprite2D" parent="Anchor/Node2D/Sprite2D"]
|
||||
position = Vector2(-2.52724e-05, 7)
|
||||
rotation = 1.5708
|
||||
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
"": SubResource("AnimationLibrary_tao4k")
|
||||
|
@ -440,16 +459,17 @@ IsDisabled = true
|
|||
[node name="CollisionShape2D" parent="Hitbox" index="0"]
|
||||
position = Vector2(4, 0)
|
||||
rotation = 1.5708
|
||||
shape = SubResource("CapsuleShape2D_ic623")
|
||||
shape = SubResource("ConvexPolygonShape2D_fcgvv")
|
||||
disabled = true
|
||||
|
||||
[node name="SwingSprite" type="Sprite2D" parent="."]
|
||||
modulate = Color(2, 2, 2, 1)
|
||||
texture = ExtResource("5_pywek")
|
||||
texture = ExtResource("10_672jv")
|
||||
offset = Vector2(8, 0)
|
||||
hframes = 4
|
||||
hframes = 5
|
||||
|
||||
[node name="SwingSound" type="AudioStreamPlayer2D" parent="."]
|
||||
stream = ExtResource("10_mfnl7")
|
||||
max_distance = 256.0
|
||||
|
||||
[node name="ParrySound" type="AudioStreamPlayer2D" parent="."]
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
[gd_resource type="ConvexPolygonShape2D" format=3 uid="uid://dw4e4r2yxwk1b"]
|
||||
|
||||
[resource]
|
||||
points = PackedVector2Array(0, 0, -21.213, 21.213, -30, 0, -21.213, -21.213, 0, -30, 21.213, -21.213, 30, 0, 21.213, 21.213, 0, 0)
|
|
@ -1,8 +1,27 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://1pb3mpmrl7lc"]
|
||||
[gd_scene load_steps=4 format=3 uid="uid://1pb3mpmrl7lc"]
|
||||
|
||||
[ext_resource type="Script" path="res://Utils/World.cs" id="1_1k6ew"]
|
||||
[ext_resource type="PackedScene" uid="uid://b2x17su05ou5w" path="res://Scenes/Maps/Arena.tscn" id="2_avsrq"]
|
||||
[ext_resource type="PackedScene" uid="uid://bxo553hblp6nf" path="res://UI/HealthBar.tscn" id="3_5rhge"]
|
||||
|
||||
[node name="World" type="Node2D"]
|
||||
[node name="World" type="Node2D" node_paths=PackedStringArray("Control")]
|
||||
script = ExtResource("1_1k6ew")
|
||||
StartingArea = ExtResource("2_avsrq")
|
||||
Control = NodePath("CanvasLayer/UI")
|
||||
|
||||
[node name="CanvasLayer" type="CanvasLayer" parent="."]
|
||||
|
||||
[node name="UI" type="Control" parent="CanvasLayer"]
|
||||
z_index = 128
|
||||
layout_mode = 3
|
||||
anchors_preset = 0
|
||||
offset_right = 640.0
|
||||
offset_bottom = 480.0
|
||||
|
||||
[node name="HealthBar" parent="CanvasLayer/UI" instance=ExtResource("3_5rhge")]
|
||||
layout_mode = 1
|
||||
anchors_preset = 1
|
||||
anchor_left = 1.0
|
||||
anchor_bottom = 0.0
|
||||
grow_horizontal = 0
|
||||
grow_vertical = 1
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
[gd_scene load_steps=14 format=3 uid="uid://b2x17su05ou5w"]
|
||||
[gd_scene load_steps=15 format=3 uid="uid://b2x17su05ou5w"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://clwv2owvk6abe" path="res://Scenes/BaseMap.tscn" id="1_ifiic"]
|
||||
[ext_resource type="Texture2D" uid="uid://b0yiy7w8nxmas" path="res://Assets/Sprites/arena-tileset.png" id="2_wnjm0"]
|
||||
|
@ -6,18 +6,46 @@
|
|||
[ext_resource type="Shader" path="res://Shaders/Flash.gdshader" id="5_h8k5p"]
|
||||
[ext_resource type="PackedScene" uid="uid://c1w7t6irnohfx" path="res://Entities/Torch.tscn" id="6_1wwor"]
|
||||
[ext_resource type="PackedScene" uid="uid://ceadk7pam7vab" path="res://Entities/TorchLamp.tscn" id="6_jy3pc"]
|
||||
[ext_resource type="Texture2D" uid="uid://d1ukste16yq6v" path="res://Assets/Sprites/Particles/player-light.png" id="7_y7j0e"]
|
||||
|
||||
[sub_resource type="OccluderPolygon2D" id="OccluderPolygon2D_8jil2"]
|
||||
polygon = PackedVector2Array(-8, -4, -6, -5, -6, -18, 6, -18, 6, -5, 8, -4, 8, 4, 4, 8, -4, 8, -8, 3.5)
|
||||
[sub_resource type="CanvasTexture" id="CanvasTexture_3n6aa"]
|
||||
diffuse_texture = ExtResource("2_wnjm0")
|
||||
|
||||
[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_fcd6d"]
|
||||
texture = ExtResource("2_wnjm0")
|
||||
texture = SubResource("CanvasTexture_3n6aa")
|
||||
use_texture_padding = false
|
||||
0:0/0 = 0
|
||||
0:0/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
0:0/0/physics_layer_0/angular_velocity = 0.0
|
||||
1:1/0 = 0
|
||||
1:1/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
1:1/0/physics_layer_0/angular_velocity = 0.0
|
||||
2:1/0 = 0
|
||||
2:1/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
2:1/0/physics_layer_0/angular_velocity = 0.0
|
||||
2:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
2:2/0 = 0
|
||||
2:2/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
2:2/0/physics_layer_0/angular_velocity = 0.0
|
||||
2:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, 0, 8, 0, 8, 8, -8, 8)
|
||||
1:0/0 = 0
|
||||
1:0/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
1:0/0/physics_layer_0/angular_velocity = 0.0
|
||||
0:1/0 = 0
|
||||
0:1/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
0:1/0/physics_layer_0/angular_velocity = 0.0
|
||||
0:2/0 = 0
|
||||
0:2/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
0:2/0/physics_layer_0/angular_velocity = 0.0
|
||||
0:3/0 = 0
|
||||
0:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
0:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
1:3/0 = 0
|
||||
1:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
1:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
1:2/0 = 0
|
||||
1:2/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
1:2/0/physics_layer_0/angular_velocity = 0.0
|
||||
2:0/0 = 0
|
||||
2:0/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
2:0/0/physics_layer_0/angular_velocity = 0.0
|
||||
|
@ -35,94 +63,68 @@ texture = ExtResource("2_wnjm0")
|
|||
6:0/0 = 0
|
||||
6:0/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
6:0/0/physics_layer_0/angular_velocity = 0.0
|
||||
7:0/size_in_atlas = Vector2i(1, 2)
|
||||
7:0/0 = 0
|
||||
7:0/0/texture_origin = Vector2i(0, 8)
|
||||
7:0/0/occlusion_layer_0/polygon = SubResource("OccluderPolygon2D_8jil2")
|
||||
7:0/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
7:0/0/physics_layer_0/angular_velocity = 0.0
|
||||
7:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -4, 8, -4, 8, 3.5, 4.5, 8, -4, 8, -8, 4)
|
||||
0:1/0 = 0
|
||||
0:1/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
0:1/0/physics_layer_0/angular_velocity = 0.0
|
||||
1:1/0 = 0
|
||||
1:1/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
1:1/0/physics_layer_0/angular_velocity = 0.0
|
||||
2:1/0 = 0
|
||||
2:1/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
2:1/0/physics_layer_0/angular_velocity = 0.0
|
||||
2:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
3:1/0 = 0
|
||||
3:1/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
3:1/0/physics_layer_0/angular_velocity = 0.0
|
||||
3:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
4:1/0 = 0
|
||||
4:1/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
4:1/0/physics_layer_0/angular_velocity = 0.0
|
||||
4:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
5:1/0 = 0
|
||||
5:1/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
5:1/0/physics_layer_0/angular_velocity = 0.0
|
||||
5:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
6:1/0 = 0
|
||||
6:1/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
6:1/0/physics_layer_0/angular_velocity = 0.0
|
||||
6:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
0:2/0 = 0
|
||||
0:2/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
0:2/0/physics_layer_0/angular_velocity = 0.0
|
||||
0:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
1:2/0 = 0
|
||||
1:2/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
1:2/0/physics_layer_0/angular_velocity = 0.0
|
||||
1:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
2:2/0 = 0
|
||||
2:2/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
2:2/0/physics_layer_0/angular_velocity = 0.0
|
||||
5:1/0 = 0
|
||||
5:1/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
5:1/0/physics_layer_0/angular_velocity = 0.0
|
||||
5:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
4:1/0 = 0
|
||||
4:1/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
4:1/0/physics_layer_0/angular_velocity = 0.0
|
||||
4:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
3:1/0 = 0
|
||||
3:1/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
3:1/0/physics_layer_0/angular_velocity = 0.0
|
||||
3:1/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
3:2/0 = 0
|
||||
3:2/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
3:2/0/physics_layer_0/angular_velocity = 0.0
|
||||
3:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
3:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 0, -8, 0)
|
||||
3:3/0 = 0
|
||||
3:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
3:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
3:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(0, -8, 8, -8, 8, 8, 0, 8)
|
||||
2:3/0 = 0
|
||||
2:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
2:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
2:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 0, -8, 0, 8, -8, 8)
|
||||
4:3/0 = 0
|
||||
4:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
4:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
4:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(8, -8, 8, 0, 0, 0, 0, -8)
|
||||
4:2/0 = 0
|
||||
4:2/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
4:2/0/physics_layer_0/angular_velocity = 0.0
|
||||
4:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(0, 0, 8, 0, 8, 8, 0, 8)
|
||||
5:2/0 = 0
|
||||
5:2/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
5:2/0/physics_layer_0/angular_velocity = 0.0
|
||||
5:2/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, 0, 0, 0, 0, 8, -8, 8)
|
||||
5:3/0 = 0
|
||||
5:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
5:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
5:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 0, -8, 0, 0, -8, 0)
|
||||
6:3/0 = 0
|
||||
6:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
6:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
6:2/0 = 0
|
||||
6:2/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
6:2/0/physics_layer_0/angular_velocity = 0.0
|
||||
7:2/0 = 0
|
||||
7:2/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
7:2/0/physics_layer_0/angular_velocity = 0.0
|
||||
0:3/0 = 0
|
||||
0:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
0:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
0:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
1:3/0 = 0
|
||||
1:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
1:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
1:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
2:3/0 = 0
|
||||
2:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
2:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
2:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
3:3/0 = 0
|
||||
3:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
3:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
3:3/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -8, 8, -8, 8, 8, -8, 8)
|
||||
4:3/0 = 0
|
||||
4:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
4:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
5:3/0 = 0
|
||||
5:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
5:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
6:3/0 = 0
|
||||
6:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
6:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
7:3/0 = 0
|
||||
7:3/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
7:3/0/physics_layer_0/angular_velocity = 0.0
|
||||
7:0/size_in_atlas = Vector2i(1, 2)
|
||||
7:0/0 = 0
|
||||
7:0/0/texture_origin = Vector2i(0, 8)
|
||||
7:0/0/physics_layer_0/linear_velocity = Vector2(0, 0)
|
||||
7:0/0/physics_layer_0/angular_velocity = 0.0
|
||||
7:0/0/physics_layer_0/polygon_0/points = PackedVector2Array(-8, -5, 8, -5, 8, 4, 4, 8, -4, 8, -8, 4)
|
||||
|
||||
[sub_resource type="OccluderPolygon2D" id="OccluderPolygon2D_kbvre"]
|
||||
polygon = PackedVector2Array(-4, 8, -8, 4, -8, -4, -6, -4, -6, -20, 6, -20, 6, -4, 8, -4, 8, 4, 4, 8)
|
||||
|
@ -249,7 +251,7 @@ physics_layer_0/collision_layer = 1
|
|||
sources/2 = SubResource("TileSetAtlasSource_5yxvt")
|
||||
sources/0 = SubResource("TileSetAtlasSource_fcd6d")
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_hcbtx"]
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_88hwc"]
|
||||
resource_local_to_scene = true
|
||||
shader = ExtResource("5_h8k5p")
|
||||
shader_parameter/color = Quaternion(1, 1, 1, 1)
|
||||
|
@ -265,114 +267,94 @@ layer_3/tile_data = PackedInt32Array(-196612, 65536, 1, -131076, 65536, 1, -6554
|
|||
layer_4/tile_data = PackedInt32Array(-524296, 327680, 0, -589818, 262144, 0, -589817, 262144, 1, -589819, 327680, 0, -589820, 196608, 1, -589821, 327680, 1, -589822, 131072, 1, -589823, 262144, 1, -589824, 327680, 0, -524289, 131072, 1, -524290, 327680, 0, -524291, 327680, 1, -524292, 327680, 1, -524293, 327680, 0, -524294, 131072, 1, -524295, 262144, 1, -589832, 131072, 2, -589831, 131072, 2, -589830, 131072, 2, -589829, 131072, 2, -589828, 131072, 2, -589827, 131072, 2, -589826, 131072, 2, -589825, 131072, 2, -655360, 131072, 2, -655359, 131072, 2, -655358, 131072, 2, -655357, 131072, 2, -655356, 131072, 2, -655355, 131072, 2, -655354, 131072, 2, -655353, 131072, 2, -655352, 327680, 2, -589833, 262144, 2, -524297, 196608, 3, -458761, 196608, 3, -393225, 196608, 3, -327689, 196608, 3, -262153, 196608, 3, -196617, 196608, 3, -131081, 196608, 3, -65545, 196608, 3, -9, 196608, 3, 65527, 196608, 3, 131063, 196608, 3, 196599, 196608, 3, 262135, 196608, 3, 327671, 196608, 3, 393207, 196608, 3, 458743, 196608, 3, 524279, 196608, 3, 262152, 131072, 3, 327688, 131072, 3, 393224, 131072, 3, 458760, 131072, 3, 196616, 131072, 3, 131080, 131072, 3, 65544, 131072, 3, 8, 131072, 3, -65528, 131072, 3, -131064, 131072, 3, -196600, 131072, 3, -262136, 131072, 3, -589816, 131072, 3, -524280, 131072, 3, -458744, 131072, 3, -393208, 131072, 3, -327672, 131072, 3, 589816, 196608, 2, 589817, 196608, 2, 589818, 196608, 2, 589819, 196608, 2, 589820, 196608, 2, 589821, 196608, 2, 589822, 196608, 2, 589823, 196608, 2, 524288, 196608, 2, 524289, 196608, 2, 524290, 196608, 2, 524291, 196608, 2, 524292, 196608, 2, 524293, 196608, 2, 524294, 196608, 2, 524295, 196608, 2, 524296, 327680, 3, 589815, 262144, 3)
|
||||
|
||||
[node name="CanvasModulate" parent="." index="0"]
|
||||
color = Color(0.588235, 0.588235, 0.588235, 1)
|
||||
color = Color(0.682353, 0.643137, 0.866667, 1)
|
||||
|
||||
[node name="TorchLamp" parent="Entities" index="0" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(-96, -120)
|
||||
|
||||
[node name="TorchLamp2" parent="Entities" index="1" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(-48, -120)
|
||||
|
||||
[node name="TorchLamp3" parent="Entities" index="2" instance=ExtResource("6_jy3pc")]
|
||||
[node name="TorchLamp3" parent="Entities" index="1" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(0, -120)
|
||||
|
||||
[node name="TorchLamp4" parent="Entities" index="3" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(48, -120)
|
||||
|
||||
[node name="TorchLamp5" parent="Entities" index="4" instance=ExtResource("6_jy3pc")]
|
||||
[node name="TorchLamp5" parent="Entities" index="2" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(96, -120)
|
||||
|
||||
[node name="TorchLamp6" parent="Entities" index="5" instance=ExtResource("6_jy3pc")]
|
||||
[node name="TorchLamp6" parent="Entities" index="3" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(-120, -96)
|
||||
|
||||
[node name="TorchLamp7" parent="Entities" index="6" instance=ExtResource("6_jy3pc")]
|
||||
[node name="TorchLamp7" parent="Entities" index="4" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(120, -96)
|
||||
|
||||
[node name="TorchLamp8" parent="Entities" index="7" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(120, -49)
|
||||
|
||||
[node name="TorchLamp9" parent="Entities" index="8" instance=ExtResource("6_jy3pc")]
|
||||
[node name="TorchLamp9" parent="Entities" index="5" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(120, -1)
|
||||
|
||||
[node name="TorchLamp10" parent="Entities" index="9" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(120, 47)
|
||||
|
||||
[node name="TorchLamp11" parent="Entities" index="10" instance=ExtResource("6_jy3pc")]
|
||||
[node name="TorchLamp11" parent="Entities" index="6" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(120, 95)
|
||||
|
||||
[node name="TorchLamp12" parent="Entities" index="11" instance=ExtResource("6_jy3pc")]
|
||||
[node name="TorchLamp12" parent="Entities" index="7" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(97, 120)
|
||||
|
||||
[node name="TorchLamp13" parent="Entities" index="12" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(47, 120)
|
||||
|
||||
[node name="TorchLamp14" parent="Entities" index="13" instance=ExtResource("6_jy3pc")]
|
||||
[node name="TorchLamp14" parent="Entities" index="8" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(0, 120)
|
||||
|
||||
[node name="TorchLamp15" parent="Entities" index="14" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(-48, 120)
|
||||
|
||||
[node name="TorchLamp16" parent="Entities" index="15" instance=ExtResource("6_jy3pc")]
|
||||
[node name="TorchLamp16" parent="Entities" index="9" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(-96, 120)
|
||||
|
||||
[node name="TorchLamp17" parent="Entities" index="16" instance=ExtResource("6_jy3pc")]
|
||||
[node name="TorchLamp17" parent="Entities" index="10" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(-120, 95)
|
||||
|
||||
[node name="TorchLamp18" parent="Entities" index="17" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(-120, 47)
|
||||
|
||||
[node name="TorchLamp19" parent="Entities" index="18" instance=ExtResource("6_jy3pc")]
|
||||
[node name="TorchLamp19" parent="Entities" index="11" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(-120, -1)
|
||||
|
||||
[node name="TorchLamp20" parent="Entities" index="19" instance=ExtResource("6_jy3pc")]
|
||||
y_sort_enabled = true
|
||||
position = Vector2(-120, -49)
|
||||
|
||||
[node name="Torch" parent="Entities" index="20" instance=ExtResource("6_1wwor")]
|
||||
[node name="Torch" parent="Entities" index="12" instance=ExtResource("6_1wwor")]
|
||||
visible = false
|
||||
position = Vector2(-120, -112)
|
||||
|
||||
[node name="Torch2" parent="Entities" index="21" instance=ExtResource("6_1wwor")]
|
||||
[node name="Torch2" parent="Entities" index="13" instance=ExtResource("6_1wwor")]
|
||||
visible = false
|
||||
position = Vector2(-72, -112)
|
||||
|
||||
[node name="Torch3" parent="Entities" index="22" instance=ExtResource("6_1wwor")]
|
||||
[node name="Torch3" parent="Entities" index="14" instance=ExtResource("6_1wwor")]
|
||||
visible = false
|
||||
position = Vector2(-24, -113)
|
||||
|
||||
[node name="Torch4" parent="Entities" index="23" instance=ExtResource("6_1wwor")]
|
||||
[node name="Torch4" parent="Entities" index="15" instance=ExtResource("6_1wwor")]
|
||||
visible = false
|
||||
position = Vector2(24, -112)
|
||||
|
||||
[node name="Torch5" parent="Entities" index="24" instance=ExtResource("6_1wwor")]
|
||||
[node name="Torch5" parent="Entities" index="16" instance=ExtResource("6_1wwor")]
|
||||
visible = false
|
||||
position = Vector2(72, -112)
|
||||
|
||||
[node name="Torch6" parent="Entities" index="25" instance=ExtResource("6_1wwor")]
|
||||
[node name="Torch6" parent="Entities" index="17" instance=ExtResource("6_1wwor")]
|
||||
visible = false
|
||||
position = Vector2(120, -112)
|
||||
|
||||
[node name="Doc" parent="Entities" index="26" instance=ExtResource("4_ej0f3")]
|
||||
material = SubResource("ShaderMaterial_hcbtx")
|
||||
[node name="Doc" parent="Entities" index="18" instance=ExtResource("4_ej0f3")]
|
||||
material = SubResource("ShaderMaterial_88hwc")
|
||||
|
||||
[node name="PointLight2D" type="PointLight2D" parent="Entities" index="19"]
|
||||
position = Vector2(168, -42)
|
||||
energy = 1.5
|
||||
blend_mode = 2
|
||||
range_item_cull_mask = 0
|
||||
shadow_enabled = true
|
||||
shadow_color = Color(0.572549, 0.572549, 0.572549, 0)
|
||||
texture = ExtResource("7_y7j0e")
|
||||
height = 16.0
|
||||
|
||||
[node name="CanvasGroup" type="CanvasGroup" parent="Entities" index="20"]
|
||||
|
||||
[node name="Areas" parent="." index="2"]
|
||||
visible = false
|
||||
|
|
|
@ -10,7 +10,7 @@ public partial class NPCIdleState : NPCState
|
|||
public override CharacterState Process(double delta)
|
||||
{
|
||||
base.Process(delta);
|
||||
if (Character.Direction.LengthSquared() > 0)
|
||||
if (Character.Direction.LengthSquared() > 0.01f)
|
||||
{
|
||||
return MoveState;
|
||||
}
|
||||
|
|
|
@ -21,8 +21,16 @@ public partial class PlayerIdleState : PlayerState
|
|||
}
|
||||
}
|
||||
|
||||
var velocity = _player.Velocity.LengthSquared();
|
||||
if (previousState is PlayerMoveState && velocity > 16)
|
||||
// must be moving at least 4 u/s for more than 0.5 seconds
|
||||
bool shouldPlayStopAnim = false;
|
||||
|
||||
if (previousState is PlayerMoveState move)
|
||||
{
|
||||
shouldPlayStopAnim = move.MoveDuration > 0.5;
|
||||
// NOTE: more conditions may be added soon
|
||||
}
|
||||
|
||||
if (shouldPlayStopAnim)
|
||||
{
|
||||
_player.MovementAnimation.Play("stop");
|
||||
_player.MovementAnimation.Queue("idle");
|
||||
|
|
|
@ -7,15 +7,19 @@ public partial class PlayerMoveState : PlayerState
|
|||
[Export]
|
||||
public PlayerRollState RollState { get; set; }
|
||||
|
||||
public double MoveDuration { get; private set; }
|
||||
|
||||
public override IState<CharacterState> Enter(IState<CharacterState> previousState)
|
||||
{
|
||||
_player.MovementAnimation.Play("move");
|
||||
MoveDuration = 0;
|
||||
return base.Enter(previousState);
|
||||
}
|
||||
|
||||
public override CharacterState Process(double delta)
|
||||
{
|
||||
base.Process(delta);
|
||||
MoveDuration += delta;
|
||||
if (Character.Direction.LengthSquared() == 0)
|
||||
{
|
||||
return IdleState;
|
||||
|
|
|
@ -8,9 +8,12 @@ public partial class PlayerRollState : PlayerState
|
|||
|
||||
private Vector2 _rollDirection = Vector2.Zero;
|
||||
|
||||
private GpuParticles2D _particles;
|
||||
|
||||
public override void _Ready()
|
||||
{
|
||||
base._Ready();
|
||||
_particles = _player.GetNode<GpuParticles2D>("Effects/RollParticles");
|
||||
}
|
||||
|
||||
public override IState<CharacterState> Enter(IState<CharacterState> previousState)
|
||||
|
@ -28,6 +31,7 @@ public partial class PlayerRollState : PlayerState
|
|||
_player.MovementAnimation.PlayBackwards("roll");
|
||||
}
|
||||
_player.MovementAnimation.Queue("idle");
|
||||
_particles.Emitting = true;
|
||||
return base.Enter(previousState);
|
||||
}
|
||||
|
||||
|
@ -37,6 +41,7 @@ public partial class PlayerRollState : PlayerState
|
|||
// this state (e.g. from death)
|
||||
_timeLeftToRoll = 0;
|
||||
_rollDirection = Character.Direction;
|
||||
_particles.Emitting = false;
|
||||
base.Exit(nextState);
|
||||
}
|
||||
|
||||
|
|
|
@ -45,12 +45,13 @@ public partial class DocChooseAttackState : NPCState
|
|||
}
|
||||
else
|
||||
{
|
||||
_consecutiveAttacks = 0;
|
||||
_consecutiveAttacks = 1;
|
||||
}
|
||||
|
||||
if (_consecutiveAttacks > Doc.Intensity)
|
||||
{
|
||||
_consecutiveAttacks = 0;
|
||||
_consecutiveAttacks = 1;
|
||||
ResetStates();
|
||||
return ExitState;
|
||||
}
|
||||
|
||||
|
|
|
@ -38,7 +38,6 @@ public partial class DocShungiteDartState : DocAttackState
|
|||
|
||||
public override void Exit(IState<NPCState> nextState)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
protected virtual Projectile SpawnProjectile(
|
||||
|
|
|
@ -11,8 +11,7 @@ public partial class DocShungiteSpikeState : DocShungiteDartState
|
|||
{
|
||||
if (this is not DocUnwantedFrequencyState)
|
||||
{
|
||||
GetNode<AnimationPlayer>("../../Animations/Telegraph")
|
||||
.Play("shungite_spike");
|
||||
Doc.TelegraphAnimation.Play("shungite_spike");
|
||||
}
|
||||
_currentAttacks = 0;
|
||||
_currentAttackDuration = 1;
|
||||
|
@ -22,7 +21,8 @@ public partial class DocShungiteSpikeState : DocShungiteDartState
|
|||
|
||||
public override void Exit(IState<NPCState> nextState)
|
||||
{
|
||||
GetNode<AnimationPlayer>("../../Animations/Telegraph").Stop();
|
||||
//Doc.TelegraphAnimation.Stop();
|
||||
//Doc.TelegraphAnimation.Stop();
|
||||
NPC.ShouldMove = true;
|
||||
}
|
||||
|
||||
|
@ -30,8 +30,7 @@ public partial class DocShungiteSpikeState : DocShungiteDartState
|
|||
Vector2 position,
|
||||
Vector2 direction)
|
||||
{
|
||||
GetNode<AnimationPlayer>("../../Animations/Telegraph")
|
||||
.Play("shungite_spike");
|
||||
Doc.TelegraphAnimation.Play("shungite_spike");
|
||||
var projectile = base.SpawnProjectile(position, direction)
|
||||
as ShungiteSpike;
|
||||
projectile.GlobalRotation = 0;
|
||||
|
@ -46,6 +45,7 @@ public partial class DocShungiteSpikeState : DocShungiteDartState
|
|||
|
||||
protected override void Attack()
|
||||
{
|
||||
GD.Print("shungite spike");
|
||||
var player = _world.CurrentPlayer;
|
||||
var playerPos = player.GlobalPosition;
|
||||
var docPos = NPC.GlobalPosition;
|
||||
|
|
|
@ -19,8 +19,8 @@ public partial class DocTelegraphState : NPCState
|
|||
{
|
||||
_currentDuration = Duration;
|
||||
TelegraphAnimationPlayer.Play("enter_in");
|
||||
float randX = GD.RandRange(-128, 128);
|
||||
float randY = GD.RandRange(-128, 128);
|
||||
float randX = GD.RandRange(-112, 112);
|
||||
float randY = GD.RandRange(-112, 112);
|
||||
NPC.GlobalPosition = new Vector2(randX, randY);
|
||||
return null;
|
||||
}
|
||||
|
|
|
@ -7,18 +7,16 @@ public partial class DocUnwantedFrequencyState : DocShungiteSpikeState
|
|||
{
|
||||
public override NPCState Enter(IState<NPCState> previous)
|
||||
{
|
||||
GetNode<AnimationPlayer>("../../Animations/Telegraph")
|
||||
.Play("unwanted_frequencies");
|
||||
NPC.ShouldMove = false;
|
||||
Doc.TelegraphAnimation.Play("unwanted_frequencies");
|
||||
return base.Enter(previous);
|
||||
}
|
||||
|
||||
public override void Exit(IState<NPCState> nextState)
|
||||
{
|
||||
GetNode<AnimationPlayer>("../../Animations/Telegraph").Stop();
|
||||
GetNode<GpuParticles2D>("../../Effects/UnwantedFrequenciesParticles")
|
||||
.Emitting = false;
|
||||
NPC.ShouldMove = true;
|
||||
GD.Print("Exit unwanted frequency");
|
||||
base.Exit(nextState);
|
||||
}
|
||||
|
||||
protected override Projectile SpawnProjectile(
|
||||
|
@ -35,6 +33,8 @@ public partial class DocUnwantedFrequencyState : DocShungiteSpikeState
|
|||
|
||||
protected override void Attack()
|
||||
{
|
||||
Doc.TelegraphAnimation.Play("unwanted_frequencies");
|
||||
GD.Print("unwanted frequency");
|
||||
var player = _world.CurrentPlayer;
|
||||
var playerPos = player.GlobalPosition;
|
||||
var docPos = NPC.GlobalPosition;
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
using Godot;
|
||||
|
||||
namespace SupaLidlGame.UI;
|
||||
|
||||
public partial class HealthBar : Control
|
||||
{
|
||||
public TextureProgressBar ProgressBar { get; set; }
|
||||
|
||||
public override void _Ready()
|
||||
{
|
||||
ProgressBar = GetNode<TextureProgressBar>("TextureProgressBar");
|
||||
}
|
||||
}
|
|
@ -1,6 +1,8 @@
|
|||
[gd_scene load_steps=2 format=3 uid="uid://bxo553hblp6nf"]
|
||||
[gd_scene load_steps=4 format=3 uid="uid://bxo553hblp6nf"]
|
||||
|
||||
[ext_resource type="FontFile" uid="uid://cgwa8bjiyv534" path="res://Assets/Fonts/alagard.ttf" id="1_700b8"]
|
||||
[ext_resource type="Script" path="res://UI/HealthBar.cs" id="1_54tsn"]
|
||||
[ext_resource type="Texture2D" uid="uid://b75oak1nd2q6x" path="res://Assets/Sprites/UI/over-under-bar.png" id="1_hlbrd"]
|
||||
[ext_resource type="Texture2D" uid="uid://co7xm7i5f6n51" path="res://Assets/Sprites/UI/progress-bar.png" id="2_62osq"]
|
||||
|
||||
[node name="HealthBar" type="Control"]
|
||||
layout_mode = 3
|
||||
|
@ -9,10 +11,18 @@ anchor_right = 1.0
|
|||
anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
script = ExtResource("1_54tsn")
|
||||
|
||||
[node name="ProgressBar" type="ProgressBar" parent="."]
|
||||
[node name="TextureProgressBar" type="TextureProgressBar" parent="."]
|
||||
texture_filter = 1
|
||||
layout_mode = 0
|
||||
offset_right = 128.0
|
||||
offset_bottom = 32.0
|
||||
theme_override_fonts/font = ExtResource("1_700b8")
|
||||
step = 1.0
|
||||
value = 84.0
|
||||
offset_bottom = 8.0
|
||||
value = 50.0
|
||||
nine_patch_stretch = true
|
||||
stretch_margin_left = 3
|
||||
stretch_margin_top = 3
|
||||
stretch_margin_right = 3
|
||||
stretch_margin_bottom = 3
|
||||
texture_under = ExtResource("1_hlbrd")
|
||||
texture_progress = ExtResource("2_62osq")
|
||||
|
|
|
@ -53,7 +53,7 @@ public partial class AnimationManager : Node
|
|||
p1.AnimationChanged += (StringName oldName, StringName newName) =>
|
||||
{
|
||||
var anim = p1.GetAnimation(oldName);
|
||||
GD.Print(oldName + "resolve");
|
||||
//GD.Print(oldName + "resolve");
|
||||
ResolveConflicts(anim);
|
||||
RemoveAllHolds(anim);
|
||||
};
|
||||
|
@ -108,7 +108,7 @@ public partial class AnimationManager : Node
|
|||
hold.TrackIndex = p1Track;
|
||||
anim1.TrackSetEnabled(p1Track, false);
|
||||
}
|
||||
GD.Print($"{hold.PriorityAnim.ResourceName} > {hold.HoldAnim.ResourceName}");
|
||||
//GD.Print($"{hold.PriorityAnim.ResourceName} > {hold.HoldAnim.ResourceName}");
|
||||
_holds.Add(hold);
|
||||
break;
|
||||
}
|
||||
|
@ -129,7 +129,7 @@ public partial class AnimationManager : Node
|
|||
// be enabled
|
||||
if (hold.PriorityAnim == anim)
|
||||
{
|
||||
GD.Print($"{anim.ResourceName} was holding ${hold.HoldAnim.ResourceName}");
|
||||
//GD.Print($"{anim.ResourceName} was holding ${hold.HoldAnim.ResourceName}");
|
||||
_holds.RemoveAt(i);
|
||||
i--;
|
||||
|
||||
|
@ -137,13 +137,13 @@ public partial class AnimationManager : Node
|
|||
// enable the track
|
||||
if (_holds.FindIndex(h => h.HoldAnim == hold.HoldAnim && h.TrackIndex == hold.TrackIndex) < 0)
|
||||
{
|
||||
GD.Print($"{hold.HoldAnim.ResourceName} is now free");
|
||||
//GD.Print($"{hold.HoldAnim.ResourceName} is now free");
|
||||
hold.HoldAnim.TrackSetEnabled(hold.TrackIndex, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
GD.Print("There are currently " + _holds.Count + " holds");
|
||||
//GD.Print("There are currently " + _holds.Count + " holds");
|
||||
}
|
||||
|
||||
private void RemoveAllHolds(Animation anim)
|
||||
|
|
|
@ -3,8 +3,7 @@
|
|||
[ext_resource type="Script" path="res://Utils/PlayerCamera.cs" id="1_jabhk"]
|
||||
|
||||
[node name="Camera2D" type="Camera2D"]
|
||||
current = true
|
||||
zoom = Vector2(4, 4)
|
||||
zoom = Vector2(2, 2)
|
||||
script = ExtResource("1_jabhk")
|
||||
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
|
|
|
@ -17,6 +17,9 @@ public partial class World : Node2D
|
|||
[Export]
|
||||
public Player CurrentPlayer { get; set; }
|
||||
|
||||
[Export]
|
||||
public Control Control { get; set; }
|
||||
|
||||
private Dictionary<string, Map> _maps;
|
||||
|
||||
private string _currentConnector;
|
||||
|
@ -56,6 +59,13 @@ public partial class World : Node2D
|
|||
};
|
||||
};
|
||||
|
||||
CurrentPlayer.Hurt += (Events.HealthChangedArgs args) =>
|
||||
{
|
||||
var bar = Control.GetNode<UI.HealthBar>("HealthBar");
|
||||
GD.Print("Set health bar");
|
||||
bar.ProgressBar.Value = args.NewHealth;
|
||||
};
|
||||
|
||||
base._Ready();
|
||||
}
|
||||
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
[gd_resource type="AudioBusLayout" format=3 uid="uid://ljp6denwxmye"]
|
||||
|
||||
[resource]
|
|
@ -1,11 +1,28 @@
|
|||
#+TITLE: SupaLidlGame To-do List
|
||||
|
||||
* List of what to add
|
||||
|
||||
** STARTED Campfires
|
||||
* STARTED Campfires
|
||||
DEADLINE: <2022-12-03 Sat>
|
||||
|
||||
** TODO Enemy Spawning
|
||||
* TODO Enemy Spawning
|
||||
|
||||
** TODO Handle Character Death
|
||||
* DONE Handle Character Death
|
||||
DEADLINE: <2022-12-04 Sun>
|
||||
|
||||
* Doc Boss
|
||||
|
||||
** DONE Reset possible attacks after each cycle
|
||||
CLOSED: [2023-07-21 Fri]
|
||||
|
||||
** DONE Attack animations
|
||||
CLOSED: [2023-07-20 Thu]
|
||||
|
||||
** TODO Boss Music
|
||||
|
||||
* TODO Boss cards
|
||||
|
||||
* TODO Dialog
|
||||
|
||||
* TODO Short arena entrance
|
||||
|
||||
* TODO Video demonstration
|
||||
|
||||
|
|
|
@ -15,6 +15,13 @@ run/main_scene="res://Scenes/Level.tscn"
|
|||
config/features=PackedStringArray("4.1", "C#", "Forward Plus")
|
||||
config/icon="res://icon.svg"
|
||||
|
||||
[display]
|
||||
|
||||
window/size/viewport_width=640
|
||||
window/size/viewport_height=480
|
||||
window/stretch/mode="viewport"
|
||||
window/stretch/aspect="expand"
|
||||
|
||||
[dotnet]
|
||||
|
||||
project/assembly_name="SupaLidlGame"
|
||||
|
|