Tuesday, 19 August 2025 01:37:27

This commit is contained in:
2025-08-19 01:37:30 -04:00
parent a47a6331ee
commit dfbad40739
30 changed files with 333 additions and 80 deletions

View File

@@ -0,0 +1,22 @@
using Godot;
using System;
public partial class Caffeinate : Effect
{
public Caffeinate(Node2D OWNER) : base(OWNER)
{
_trigger.Add(Trigger.Collision);
}
public override void TriggerEffect(Node TARGET = null)
{
if (TARGET is Worker)
{
Worker target = (Worker)TARGET;
target._rotationalForce += 10;
Vector2 targetDistanceNormal = (target.Position - _owner.Position).Normalized();
target.ApplyCentralForce(targetDistanceNormal * 10);
target.ChangeHealth(-1, _owner);
}
}
}