Exemplo n.º 1
0
 public void SetShip(GameData.Ship ship)
 {
     Ship = ship;
     if (dbChar != null)
     {
         dbChar.Character.Ship = ship.Nickname;
         dbChar.ApplyChanges();
     }
 }
Exemplo n.º 2
0
        public GameData.Ship GetShip(string nickname)
        {
            var legacy = fldata.Ships.GetShip(nickname);
            var ship   = new GameData.Ship();

            foreach (var matlib in legacy.MaterialLibraries)
            {
                resource.LoadMat(matlib);
            }
            ship.Drawable        = resource.GetDrawable(legacy.DaArchetypeName);
            ship.Mass            = legacy.Mass;
            ship.AngularDrag     = legacy.AngularDrag;
            ship.RotationInertia = legacy.RotationInertia;
            ship.SteeringTorque  = legacy.SteeringTorque;
            ship.CruiseSpeed     = 300;
            ship.StrafeForce     = legacy.StrafeForce;
            return(ship);
        }
Exemplo n.º 3
0
        GameData.Ship GetShip(Data.Ships.Ship Data)
        {
            var ship = new GameData.Ship();

            foreach (var matlib in Data.MaterialLibraries)
            {
                resource.LoadResourceFile(ResolveDataPath(matlib));
            }
            ship.Drawable        = resource.GetDrawable(ResolveDataPath(Data.DaArchetypeName));
            ship.Mass            = Data.Mass;
            ship.AngularDrag     = Data.AngularDrag;
            ship.RotationInertia = Data.RotationInertia;
            ship.SteeringTorque  = Data.SteeringTorque;
            ship.CruiseSpeed     = 300;
            ship.StrafeForce     = Data.StrafeForce;
            ship.ChaseOffset     = Data.CameraOffset;
            return(ship);
        }