Ejemplo n.º 1
0
 public Entity(Texture2D texture, Vector2 position, float speed, int size, SimulationWorld world)
     : base(texture, position, size, new Rectangle(0, 0, 64, 64))
 {
     this.speed = speed;
     this.world = world;
     this.weapon = new Pistol(world, this);
 }
Ejemplo n.º 2
0
 public Spawner(SimulationWorld world)
 {
     this.world = world;
     this.timeAlive = 0;
     this.interval = 7f;
     this.spawned = 0;
     world.PlayerScore = 0;
 }
 public DecisionEnemy(Vector2 position, SimulationWorld world) : base(Globals.player, position, 100, 40, world)
 {
     Health = 150;
     MaxHealth = 150;
     color = Color.Cyan;
     weapon = new Rifle(world, this);
     GeneratePatrolPath();
 }
Ejemplo n.º 4
0
 public Hud(Camera camera, Camera cameraHud, Inputs input, SimulationWorld world)
 {
     this.camera = camera;
     this.cameraHud = cameraHud;
     this.world = world;
     this.aim = new Aim(world.Player, this);
     this.mainMenu = new MainMenu();
     this.input = input;
     menu = true;
 }
        public Player(Vector2 position, SimulationWorld world, Inputs input) : base(Globals.player, position, 250, 40, world)
        {
            this.input = input;
            PosAim = position;

            color = Color.Gold;
            this.Health = 1000;
            this.MaxHealth = 1000;
            this.weapon = new Pistol(world, this);
        }
        public FuSMEnemy(Vector2 position, SimulationWorld world) : base(Globals.player, position, 100, 40, world)
        {
            this.Machine = new FuSMMachine<FuSMEnemy>(this)
                .AddState(new ApproachState())
                .AddState(new AttackState())
                .AddState(new ForewarnState())
                .AddState(new PatrolState());

            health = 150;
            maxHealth = 150;
            color = Color.Cyan;
            weapon = new Rifle(world, this);
        }
 public BaseEnemy(Texture2D texture, Vector2 position, float speed, int size, SimulationWorld world) : base(texture, position, speed, size, world)
 {
     var rand = new Random();
     switch(rand.Next(0, 4))
     {
         case 0: weapon = new ShotGun(world, this);
             break;
         case 1: weapon = new Bazooka(world, this);
             break;
         case 2: weapon = new Rifle(world, this);
             break;
         default: weapon = new Pistol(world, this);
             break;
     }
 }
 public Pistol(SimulationWorld world, Entity owner) : base(world, owner)
 {
     cooldown = 0.4f;
     damage = 50f;
 }
 public Rifle(SimulationWorld world, Entity owner) : base(world, owner)
 {
     cooldown = 0.15f;
     damage = 10f;
 }
 public NormalEnemy(Vector2 position, SimulationWorld world) : base(Globals.player, position, 100, 40, world)
 {
     health = 150;
     maxHealth = 150;
     color = Color.DarkOliveGreen;
 }
 public PathFinder(SimulationWorld world)
 {
     this.world = world;
 }
 public Weapon(SimulationWorld world, Entity owner)
 {
     this.world = world;
     this.owner = owner;
     this.size = 10; //default size
 }
 public SlowEnemy(Vector2 position, SimulationWorld world) : base(Globals.player, position, 60, 50, world)
 {
     health = 250;
     maxHealth = 250;
     color = Color.Red;
 }
 public ShotGun(SimulationWorld world, Entity owner) : base(world, owner)
 {
     cooldown = 0.5f;
     damage = 40.0f;
 }
Ejemplo n.º 15
0
 public GameScene(GraphicsDeviceManager gdm, MainGame game)
     : base(gdm, game)
 {
     this.world = new SimulationWorld(input);
     this.hud = new Hud(camera, hudCamera, input, world);
 }
 public Bazooka(SimulationWorld world, Entity owner) : base(world, owner)
 {
     cooldown = 1.4f;
     damage = 200.0f;
     size = 20;
 }
 public BasePower(Texture2D texture, Vector2 position, int size, SimulationWorld world, Rectangle bounds) : base(texture, position, size, bounds)
 {
     this.world = world;
 }
 public WeaponCase(Vector2 position, int size, SimulationWorld world) : base(Globals.create, position, size, world, new Rectangle(0, 0, 64, 64))
 {
     this.color = Color.Yellow;
 }
 public FastEnemy(Vector2 position, SimulationWorld world) : base(Globals.player, position, 200, 30, world)
 {
     health = 70;
     maxHealth = 70;
     color = Color.Pink;
 }
 public BulletManager(SimulationWorld world)
 {
     this.world = world;
     bullets = new LinkedList<Bullet>();
     deadBullets = new LinkedList<Bullet>();
 }