Example #1
0
        public FormDebug(GameSession.GameSession RunningGameSession)
        {
            this.RunningGameSession = RunningGameSession;

            InitializeComponent();



            this.trackBarYaw.Value   = (int)(this.RunningGameSession.LODMap.GetRenderer().SunLight.Yaw / (2 * Math.PI) * 360);
            this.trackBarPitch.Value = (int)(this.RunningGameSession.LODMap.GetRenderer().SunLight.Pitch / (2 * Math.PI) * 360);
            this.trackBarRoll.Value  = (int)(this.RunningGameSession.LODMap.GetRenderer().SunLight.Roll / (2 * Math.PI) * 360);

            this.labelLightvalues.Text = "yaw: " + this.RunningGameSession.LODMap.GetRenderer().SunLight.Yaw.ToString("0.00") + " / pitch: " +
                                         this.RunningGameSession.LODMap.GetRenderer().SunLight.Pitch.ToString("0.00") + " / roll: " + this.RunningGameSession.LODMap.GetRenderer().SunLight.Roll.ToString("0.00");


            this.textBoxShadowPosX.Text = this.RunningGameSession.LODMap.GetRenderer().SunLight.ShadowLightPosition.X.ToString();
            this.textBoxShadowPosY.Text = this.RunningGameSession.LODMap.GetRenderer().SunLight.ShadowLightPosition.Y.ToString();
            this.textBoxShadowPosZ.Text = this.RunningGameSession.LODMap.GetRenderer().SunLight.ShadowLightPosition.Z.ToString();

            this.textBoxlShadowTargetX.Text = this.RunningGameSession.LODMap.GetRenderer().SunLight.ShadowLightTarget.X.ToString();
            this.textBoxlShadowTargetY.Text = this.RunningGameSession.LODMap.GetRenderer().SunLight.ShadowLightTarget.Y.ToString();
            this.textBoxlShadowTargetZ.Text = this.RunningGameSession.LODMap.GetRenderer().SunLight.ShadowLightTarget.Z.ToString();

            this.textBoxShadowFarPlane.Text = this.RunningGameSession.LODMap.GetRenderer().shadowFarPlane.ToString();

            this.textBoxShadowBias.Text = (1.0f / this.RunningGameSession.LODMap.GetRenderer().ShadowBias).ToString();

            this.textBoxNormalBias.Text = this.RunningGameSession.LODMap.GetRenderer().NormalBias.ToString();
        }
Example #2
0
        public AnimTest(GameSession.GameSession RuningGameSession)
            : base(RuningGameSession)
        {
            this.model = new AnimatedModel("test2/Victoria-hat-tpose");
            this.model.LoadContent(this.RunningGameSession.Content);

            base.model = this.model.model;

            dance = new AnimatedModel("test2/Victoria-hat-dance");
            dance.LoadContent(this.RunningGameSession.Content);

            // Obtain the clip we want to play. I'm using an absolute index,
            // because XNA 4.0 won't allow you to have more than one animation
            // associated with a model, anyway. It would be easy to add code
            // to look up the clip by name and to index it by name in the model.
            AnimationClip clip = dance.Clips[0];


            // And play the clip
            AnimationPlayer player = model.PlayClip(clip);

            player.Looping = true;


            //    this.Rotation = new Vector3(0.0f, 0.0f, (float)(Math.PI/2));
        }
Example #3
0
        public Simulator(GameSession.GameSession RunningGameSession)
        {
            EventQueue              = new Queue <Event>();
            SimEntities             = new List <Simulation.Events.EventReceiver>();
            this.RunningGameSession = RunningGameSession;

            MapModified = false;
        }
Example #4
0
        public EntityFlyer(GameSession.GameSession RuningGameSession)
            : base(RuningGameSession)
        {
            this.MaxSpeed = 10.0f;
            this.Velocity = new Vector3(0.0f, 0.0f, -1.0f);

            this.AddTexture("CubeTex");
            this.LoadModel("Models/Cube"); //, this.effect);
            CorrectBoundingBox  = true;
            this.Type           = EntityTypes.FLYER;
            this.CanBeCommanded = false;
            this.IsMover        = true;
        }
Example #5
0
        public LODTerrain(GameSession.GameSession RunningGameSession, int mapNumCellsPerRow, int mapNumCellPerColumn, Effect effect, GraphicsDevice device, GameSession.GameStorage storage)
        {
            this.RunningGameSession = RunningGameSession;

            playerLight       = new PPPointLight(new Vector3(0, 0, 0), Color.White * 0.50f, 100);
            this.playerCamera = this.RunningGameSession.PlayerCamera;

            modelEffect = this.RunningGameSession.Content.Load <Effect>("PrelightEffects");


            CreateNewMap(mapNumCellsPerRow, mapNumCellPerColumn, device, storage);

            prelightRender = new PrelightingRenderer(this.RunningGameSession, effect, device, entities);

            this.Initialize();
        }
Example #6
0
 public Lander(GameSession.GameSession RuningGameSession)
     : base(RuningGameSession)
 {
     this.Type         = EntityTypes.LANDER;
     this.CurrentState = States.UNDER_CONSTRUCTION;
 }
Example #7
0
 public Foundation(GameSession.GameSession RuningGameSession)
     : base(RuningGameSession)
 {
     this.Type         = EntityTypes.FOUNDATION;
     this.CurrentState = States.UNDER_CONSTRUCTION;
 }
Example #8
0
 public DebugState(GameSession.GameSession RunningGameSession)
     : base(RunningGameSession)
 {
 }
Example #9
0
 //  private Vector3 markerLocation;
 public MousePointerLook(GameSession.GameSession RunningGameSession)
     : base(RunningGameSession)
 {
 }
Example #10
0
 public AnimTest(GameSession.GameSession RuningGameSession)
     : base(RuningGameSession)
 {
     this.Type       = EntityTypes.TEST;
     this.Isanimated = true;
 }
Example #11
0
 public NotifySessionBeginAppServerPacket(GameSession.GameSession session)
 {
     Session = session;
 }
Example #12
0
 public GameState(GameSession.GameSession RunningGameSession)
 {
     this.RunningGameSession = RunningGameSession;
 }
Example #13
0
 public WindTower(GameSession.GameSession RuningGameSession)
     : base(RuningGameSession)
 {
     this.Type         = EntityTypes.WIND_TOWER;
     this.CurrentState = States.UNDER_CONSTRUCTION;
 }
Example #14
0
 public PlaceBuilding(GameSession.GameSession RunningGameSession)
     : base(RunningGameSession)
 {
     LastSelectedEntityType = Entity.EntityTypes.NONE;
 }
Example #15
0
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="gameSession">The game session to create this log entry from</param>
 public GameSessionEntry(GameSession.GameSession gameSession)
 {
     MatchName = gameSession.Name;
 }
Example #16
0
 public BasicMine(GameSession.GameSession RuningGameSession)
     : base(RuningGameSession)
 {
     this.Type = EntityTypes.BASIC_MINE;
 }
Example #17
0
 public FreeLook(GameSession.GameSession RunningGameSession)
     : base(RunningGameSession)
 {
 }
Example #18
0
 public SolarPlant(GameSession.GameSession RuningGameSession)
     : base(RuningGameSession)
 {
     this.Type         = EntityTypes.SOLAR;
     this.CurrentState = States.UNDER_CONSTRUCTION;
 }