예제 #1
0
        public playerStatus status; //håller reda på isrunning mm

        #endregion Fields

        #region Constructors

        public Player(Vector3 pos, GraphicsDevice device)
        {
            position = pos;
            camera = new Camera(device, getCameraPos());
            status = new playerStatus();
            rifle = new Weapon(camera, status);
            speedY = 0.0f;
        }
예제 #2
0
 public Player(Vector3 pos, GraphicsDevice device)
 {
     position = pos;
     camera   = new Camera(device, getCameraPos());
     status   = new playerStatus();
     rifle    = new Weapon(camera, status);
     speedY   = 0.0f;
 }
예제 #3
0
 public Weapon(Camera cam, playerStatus stat)
 {
     camera = cam;
     zRecoil = 0f;
     clip = MAXCLIP;
     rounds = MAXROUNDS;
     timer = 0.0f;
     animation = false;
     empty = false;
     reloadTimer = 0.0f;
     status = stat;
 }
예제 #4
0
 public Weapon(Camera cam, playerStatus stat)
 {
     camera      = cam;
     zRecoil     = 0f;
     clip        = MAXCLIP;
     rounds      = MAXROUNDS;
     timer       = 0.0f;
     animation   = false;
     empty       = false;
     reloadTimer = 0.0f;
     status      = stat;
 }
예제 #5
0
 public Player(float x, float y, float z, Int32 identity, Int32 charModel, GraphicsDevice device)
 {
     ChangePosition(x, y, z);
     id = identity;
     Console.WriteLine("id: " + id.ToString());
     Globals.player.id = identity;
     alive = true;
     model = charModel;
     camera = new Camera(device, getCameraPos());
     status = new playerStatus();
     rifle = new Weapon(camera, status);
     speedY = 0.0f;
     Globals.player.model = charModel;
 }
예제 #6
0
 public Player(float x, float y, float z, Int32 identity, Int32 charModel, GraphicsDevice device)
 {
     ChangePosition(x, y, z);
     id = identity;
     Console.WriteLine("id: " + id.ToString());
     Globals.player.id    = identity;
     alive                = true;
     model                = charModel;
     camera               = new Camera(device, getCameraPos());
     status               = new playerStatus();
     rifle                = new Weapon(camera, status);
     speedY               = 0.0f;
     Globals.player.model = charModel;
 }