public Wave(GameCode gc, Game game, Player player, Player opponent) { ID = Guid.NewGuid().ToString(); mCtx = gc; mGame = game; mPlayer = player; mOpponent = opponent; mWaveTimeWindow = Settings.WAVE_WINDOW; mWaveTimeElapsed = 0; mTimeToNextSpawn = 0; Points = 24; Started = false; SpawnQueue = new Queue<Creep>(); SpawnTimers = new Dictionary<Creep, long>(); CreepTypes = new List<String>(); if (mPlayer == mGame.Black) { StartingPosition = mGame.Board.WhiteSpawn.Position; } else { StartingPosition = mGame.Board.BlackSpawn.Position; } }
public Tower(Game g, Player p, Player opponent, Vector2 pos) { mGame = g; Player = p; mOpponent = opponent; Width = Settings.BOARD_CELL_WIDTH; Height = Settings.BOARD_CELL_HEIGHT; Position = pos; Cost = Costs.BASIC; FireRate = 1800; // Settings.DEFAULT_FIRE_RATE * 3; Range = Settings.DEFAULT_RANGE * 2; Damage = 30; SellValue = 7; EffectedFireRate = FireRate; EffectedDamage = Damage; EffectedRange = Range; mUpdatedRange = Range; mUpdatedRate = FireRate; mUpdatedDamage = Damage; FireRatePosition = mFireRate; StaticTarget = null; Enabled = true; }
public SniperTower(Game g, Player p, Player opponent, Vector2 pos) : base(g, p, opponent, pos) { FireRate = 1500; Range = Settings.DEFAULT_RANGE * 12; Damage = Settings.DEFAULT_DAMAGE * 25; SellValue = 210; Type = Tower.SNIPER; }
public AOESlowTower(Game g, Player p, Player opponent, Vector2 pos) : base(g, p, opponent, pos) { FireRate = 75; Range = Settings.DEFAULT_RANGE * 2; Damage = 0; SellValue = 210; Type = Tower.SLOW; }
public SeedTower(Game g, Player p, Player opponent, Vector2 pos) : base(g, p, opponent, pos) { FireRate = Settings.DEFAULT_FIRE_RATE * 30; // every 9 seconds Range = Settings.DEFAULT_RANGE * 3; Damage = Settings.DEFAULT_DAMAGE * 10; SellValue = (int)(Costs.SEED * Costs.RESELL_VALUE); Type = Tower.SEED; }
public PulseTower(Game g, Player p, Player opponent, Vector2 pos) : base(g, p, opponent, pos) { FireRate = Settings.DEFAULT_FIRE_RATE * 3; Range = Settings.DEFAULT_RANGE * 1.25f; Damage = Settings.DEFAULT_DAMAGE * 15; SellValue = 210; Type = Tower.PULSE; }
public PulseProjectile(Game game, Vector2 position, Player target, int damage, float range) : base(game, position, null, damage) { mOpponent = target; mRadius = 0.0f; mRange = range; Velocity = 5 * Settings.BOARD_CELL_WIDTH; Type = "Pulse"; Ready = false; }
public DamageBoostTower(Game g, Player p, Player opponent, Vector2 pos) : base(g, p, opponent, pos) { FireRate = 0; Range = 0; Damage = 0; SellValue = 210; EffectedFireRate = FireRate; EffectedDamage = Damage; EffectedRange = Range; Type = Tower.DAMAGE_BOOST; }
public SpellTower(Game g, Player p, Player opponent, Vector2 pos) : base(g, p, opponent, pos) { FireRate = 750; Range = 100;// Settings.DEFAULT_RANGE * 3; Damage = 70; SellValue = 75; EffectedFireRate = FireRate; EffectedDamage = Damage; EffectedRange = Range; Type = Tower.SPELL; }
public RapidFireTower(Game g, Player p, Player opponent, Vector2 pos) : base(g, p, opponent, pos) { FireRate = 200; Range = 100;// Settings.DEFAULT_RANGE * 3; Damage = 20; SellValue = 75; EffectedFireRate = FireRate; EffectedDamage = Damage; EffectedRange = Range; Type = Tower.RAPID_FIRE; }
public Projectile(Game game, Vector2 position, Creep target, int damage = Settings.DEFAULT_DAMAGE) { mGame = game; Width = 5; Height = 5; // The position passed in is the center of the tower, we need to recalc the projectiles position so the center is aligned with the center of the tower Position = new Vector2(position.X - Width / 2, position.Y - Height / 2); Target = target; Velocity = 200; Damage = damage; Type = "Basic"; Ready = false; }
public void reset(Game game) { mGame = game; Mana = Settings.DEFAULT_MANA; Life = Settings.DEFAULT_LIFE; DamageDealt = 0; lock(Towers) Towers.Clear(); lock(Creeps) Creeps.Clear(); OnDeckWaves = new List<Wave>(); QueuedWaves = new Queue<Wave>(); ActiveWaves = new List<Wave>(); WavePosition = 0; ChiBlastCost = Settings.CHI_BLAST_INITIAL; ChiBlastUses = 0; StaticTarget = ""; }
public SlowProjectile(Game game, Vector2 position, Creep target) : base(game, position, target, 0) { Type = "Slow"; }
public SniperProjectile(Game game, Vector2 position, Creep target, int damage) : base(game, position, target, damage) { Type = "Sniper"; }
public RapidFireProjectile(Game game, Vector2 position, Creep target, int damage) : base(game, position, target, damage) { Type = "RapidFire"; }