Cleanup, make the project compilable on windows using AoT, add room box to all rooms
This commit is contained in:
@@ -170,17 +170,17 @@ public partial class Enemy : CharacterBody3D, IEnemy, IProvide<IEnemyLogic>
|
||||
|
||||
private void OnAttackTimeout()
|
||||
{
|
||||
//if (GlobalPosition.DistanceTo(_player.CurrentPosition) > 5f)
|
||||
//{
|
||||
// _enemyLogic.Input(new EnemyLogic.Input.Alerted());
|
||||
// return;
|
||||
//}
|
||||
if (GlobalPosition.DistanceTo(_player.CurrentPosition) > 5f)
|
||||
{
|
||||
_enemyLogic.Input(new EnemyLogic.Input.Alerted());
|
||||
return;
|
||||
}
|
||||
|
||||
var rng = new RandomNumberGenerator();
|
||||
rng.Randomize();
|
||||
_enemyLogic.Input(new EnemyLogic.Input.AttackTimer());
|
||||
_attackTimer.Stop();
|
||||
//_attackTimer.WaitTime = rng.RandfRange(2f, 5.0f);
|
||||
_attackTimer.WaitTime = rng.RandfRange(2f, 5.0f);
|
||||
_attackTimer.Start();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user