hitting is now an ability
This commit is contained in:
@@ -372,7 +372,7 @@ tracks/3/keys = {
|
||||
}
|
||||
tracks/4/type = "method"
|
||||
tracks/4/imported = false
|
||||
tracks/4/enabled = false
|
||||
tracks/4/enabled = true
|
||||
tracks/4/path = NodePath("../..")
|
||||
tracks/4/interp = 1
|
||||
tracks/4/loop_wrap = true
|
||||
|
||||
@@ -116,12 +116,12 @@ public partial class WeaponSystem : RigidBody3D, IDamageDealer, IForgeEntity
|
||||
|
||||
#region Privates
|
||||
|
||||
private StateChart _weaponState = null!;
|
||||
private Transition _handToFlying = null!;
|
||||
private Transition _flyingToHand = null!;
|
||||
private Transition _plantedToHand = null!;
|
||||
private Transition _plantedToFlying = null!;
|
||||
private Transition _toPlanted = null!;
|
||||
private StateChart _weaponState = null!;
|
||||
private Transition _handToFlying = null!;
|
||||
private Transition _flyingToHand = null!;
|
||||
private Transition _plantedToHand = null!;
|
||||
private Transition _plantedToFlying = null!;
|
||||
private Transition _toPlanted = null!;
|
||||
|
||||
private ShapeCast3D _dashCast3D = null!;
|
||||
|
||||
@@ -177,17 +177,12 @@ public partial class WeaponSystem : RigidBody3D, IDamageDealer, IForgeEntity
|
||||
WeaponFlyingAbilityTag = Tag.RequestTag(tagsManager,"abilities.weapon.flying");
|
||||
|
||||
List<AttributeSet> attributeSetList = [];
|
||||
foreach (Node node in GetChildren())
|
||||
foreach (var node in GetChildren())
|
||||
{
|
||||
if (node is ForgeAttributeSet attributeSetNode)
|
||||
{
|
||||
AttributeSet? attributeSet = attributeSetNode.GetAttributeSet();
|
||||
|
||||
if (attributeSet is not null)
|
||||
{
|
||||
attributeSetList.Add(attributeSet);
|
||||
}
|
||||
}
|
||||
if (node is not ForgeAttributeSet attributeSetNode) continue;
|
||||
var attributeSet = attributeSetNode.GetAttributeSet();
|
||||
if (attributeSet is not null)
|
||||
attributeSetList.Add(attributeSet);
|
||||
}
|
||||
Attributes = new EntityAttributes([.. attributeSetList]);
|
||||
|
||||
@@ -458,6 +453,7 @@ public partial class WeaponSystem : RigidBody3D, IDamageDealer, IForgeEntity
|
||||
|
||||
public override void _Process(double delta)
|
||||
{
|
||||
Abilities.UpdateAbilities(delta);
|
||||
EffectsManager.UpdateEffects(delta);
|
||||
|
||||
if (!FlyingState.Active) return;
|
||||
|
||||
Reference in New Issue
Block a user