adding in some example pegs and their actions. organizing folders, still working on pathing for some reason it won't move sometimes, and causes the looping to break
This commit is contained in:
@@ -5,7 +5,7 @@ public partial class Bucket : Node2D
|
||||
{
|
||||
|
||||
[Signal]
|
||||
public delegate void AttackEnteredEventHandler(Attack ATTACK);
|
||||
public delegate void BallEnteredEventHandler(Ball BALL);
|
||||
public int _minX = -500, _maxX = 500, _movementSign = 1, _movementSpeed = 3;
|
||||
public Vector2 _startPoisition;
|
||||
|
||||
@@ -27,10 +27,10 @@ public partial class Bucket : Node2D
|
||||
}
|
||||
public void OnBodyEntered(Node2D BODY)
|
||||
{
|
||||
if (BODY is Attack attack)
|
||||
if (BODY is Ball ball)
|
||||
{
|
||||
EmitSignal(SignalName.AttackEntered, attack);
|
||||
attack.EnteredBucket();
|
||||
EmitSignal(SignalName.BallEntered, ball);
|
||||
ball.EnteredBucket();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user