public Enemy(Vector2 center, float width, float height, Hero hero) : base(center, width, height) { this.hero = hero; setColor(Game.randomColor()); enemyState = EnemyState.BEGIN; timer = new Timer(behaviorChangeTime); }
public Bullet(Vector2 genaratePosition, Vector2 currentSpeed, float radius, Hero currentHero, List <Enemy> currentEnemy) { this.position = new XNACS1Circle(genaratePosition, radius); this.position.Color = Game.randomColor(); explosions = new List <Explosion>(); // set object into motion; this.alive = true; this.hero = currentHero; this.enemies = currentEnemy; this.speed = currentSpeed; }
public Character(Vector2 position, float width, float height) { this.position = new XNACS1Rectangle(position, width, height); this.position.Color = Game.randomColor(); this.nextPosition = new XNACS1Rectangle(position, width, height); this.nextPosition.Visible = false; // set object into motion; this.position.Velocity = new Vector2(0, 0); this.alive = true; this.pendingCollisions = new List <XNACS1Rectangle>(); }