public Component3D(GameCore game, GeometricPrimitive primitiveModel, Texture2D texture)
     : base(game, texture)
 {
     this.primitiveModel = primitiveModel;
     this.mygame = game;
     this.texture = texture;
 }
 public Component3D(GameCore game, GeometricPrimitive primitiveModel, Color color)
     : base(game, null)
 {
     this.primitiveModel = primitiveModel;
     this.mygame = game;
     this.color = color;
 }
 /// <summary>
 /// The main entry point for the application.
 /// </summary>
 static void Main(string[] args)
 {
     using (GameCore game = new GameCore())
     {
         game.Run();
     }
 }
 public Component3D(GameCore game, Model model, Texture2D texture)
     : base(game, texture)
 {
     if (model != null) {
         this.model = model;
         SetupEffectDefaults(model);
     }
 }
Exemplo n.º 5
0
 //Sprite image;  como fazer
 public Fly(GameCore game, Texture2D imgInimigo, int hp, float velocidadeInimigo, int largura, Vector2 positionfly, Player player, int score)
     : base(game, imgInimigo,hp,velocidadeInimigo,largura,score)
 {
     this.positionInimigo = positionfly;
     this.player = player;
     life = mygame.Content.Load<Texture2D>("life");
     this.score = score;
 }
 public DualGuns(GameCore game, Texture2D imgInimigo, int hp, float velocidadeInimigo, int largura, int score)
     : base(game, imgInimigo,hp,velocidadeInimigo,largura,score)
 {
     life = mygame.Content.Load<Texture2D>("life");
     sprite = new Sprite(mygame, imgInimigo, 4, new Vector3(), 0);
     positionInimigo = new Vector2(20, 20);
     this.score = score;
 }
 public LancadorMisseis(GameCore game, Texture2D imgInimigo, int hp, int velocidadeInimigo, int largura, ScreenGamePlay screen, int score)
     : base(game, imgInimigo, hp, velocidadeInimigo, largura, score)
 {
     positionInimigo = new Vector2(rnd.Next(mygame.Window.ClientBounds.Width), 0);
     this.screen = screen;
     imgTiro = mygame.Content.Load<Texture2D>("missel");
     life = mygame.Content.Load<Texture2D>("life");
     this.score = score;
 }
 public Player(GameCore game, Texture2D imgPlayer, Vector2 positionPlayer, int vida, int hp, int velocidadePlayer, ScreenGamePlay screen)
     : base(game, imgPlayer)
 {
     this.positionPlayer = positionPlayer;
     this.imgPlayer = imgPlayer;
     this.vida = vida;
     this.hp = hp;
     this.velocidadePlayer = velocidadePlayer;
     this.screen = screen;
 }
 public Inimigo(GameCore game, Texture2D imgInimigo, int hp, float velocidadeInimigo, int largura,int score)
     : base(game, imgInimigo)
 {
     this.imgInimigo = imgInimigo;
     this.hp = hp;
     this.velocidadeInimigo = velocidadeInimigo;
     this.largura = largura;
     this.altura = imgInimigo.Height;
     this.score = score;
 }
 public Inimigo(GameCore game, Texture2D imgInimigo, int hp, int velocidadeInimigo, int largura)
     : base(game, imgInimigo)
 {
     positionInimigo = new Vector2(rnd.Next(mygame.Window.ClientBounds.Width), -50);
     this.imgInimigo = imgInimigo;
     this.hp = hp;
     this.velocidadeInimigo = velocidadeInimigo;
     this.largura = largura;
     this.altura = imgInimigo.Height;
 }
 public Metralhadora(GameCore game, Texture2D imgInimigo, int hp, float velocidadeInimigo, int largura, Screen screen, int score)
     : base(game, imgInimigo, hp, velocidadeInimigo, largura, score)
 {
     life = mygame.Content.Load<Texture2D>("life");
     sprite = new Sprite(mygame, imgInimigo, 8, new Vector3(), 0);
     positionInimigo = new Vector2(49, 20);
     tiro = mygame.Content.Load<Texture2D>("TiroPlayer");
     this.screen = screen;
     this.score = score;
 }
 public ScreenGamePlay(GameCore game)
     : base(game)
 {
     bg = mygame.Content.Load<Texture2D>("bg");
     int width = game.Window.ClientBounds.Right - game.Window.ClientBounds.Left;
     int height = game.Window.ClientBounds.Bottom - game.Window.ClientBounds.Top;
     while (width > 0) {
         width -= 200;
         int htemp = height;
         while (htemp > -200) {
             htemp -= 200;
             bgpos.Add(new Vector2(width, htemp));
         }
     }
     szbg = bgpos.Count;
     mygame.sons.playSong(2);
 }
 public Component(GameCore game)
 {
     // TODO: Complete member initialization
     this.game = game;
 }
 public Component(GameCore game, Texture2D texture)
 {
     this.texture = texture;
     this.mygame = game;
     this.alpha = 255;//opaco
 }
 public Component3D(GameCore game, Texture2D texture)
     : base(game, texture)
 {
 }
 public RepositorioDeModelos(GameCore game)
 {
 }