public Minion(float x, float y, Utility.MinionType type) { Position = new Vector2(x, y); _inBetween = 0; _distanceTraveled = 0; _waypoints = new List <Waypoint>(); _stackFlamethrowers = new List <FireStack>(); _fireClock = new CoolDownTimer(1); _fireClock.Reset(); _type = type; if (_type == Utility.MinionType.Fast) { _hp = Utility.FastMinionHP; MaxHP = Utility.FastMinionHP; _speed = 0.002f; _radius = 0.2f; } else if (_type == Utility.MinionType.Slow) { _hp = Utility.SlowMinionHP; MaxHP = Utility.SlowMinionHP; _speed = 0.0005f; _radius = 0.4f; } else if (_type == Utility.MinionType.Boss) { _hp = Utility.BossMinionHp; MaxHP = Utility.BossMinionHp; _speed = 0.0001f; _radius = 0.6f; } _healthBar = new HealthBar(this); }
public Spawner() { _timer1 = new CoolDownTimer(1); _timer1.Reset(); _timer2 = new CoolDownTimer(5); _timer2.Reset(); IsActive = true; }
public Path() { pathway = new List <Tile>(); MinionList = new List <Minion>(); _spawnSequenceTimer = new CoolDownTimer(0.2f); _spawnSequenceTimer.Reset(); _pathsShown = 0; Sequence = Animation.Spawn; _minionSpawner = new CoolDownTimer(10f); _minionSpawner.Reset(); _spawner = new Spawner(); _done = false; }
public Board(int iWidth, int iHeight) { Width = iWidth; Height = iHeight; Paths = new List <Path>(); OldPaths = new List <Path>(); _tiles = new Tile[FullWidth, FullHeight]; _bossTimer = new CoolDownTimer(60); _bossTimer.Reset(); for (int i = 0; i < FullWidth; i++) { for (int j = 0; j < FullHeight; j++) { _tiles[i, j] = new Tile(i, j); } } CacheGridSize(); }