Пример #1
0
 public RaceCompletedView(Vehicle vehicle)
 {
     _camera = new FixedChaseCamera(6.3f, 2.3f);
     _camera.FieldOfView = MathHelper.ToRadians(55.55f);
     _camera.RotationSpeed = 0.8f;
     _camera.MinHeight = 10;
 }
Пример #2
0
        public ChaseView(Vehicle vehicle)
        {
            _camera = new FixedChaseCamera(DefaultChaseDistance, DefaultChaseHeight);
            _camera.FieldOfView = MathHelper.ToRadians(55.55f);

            _vehicle = vehicle;

            _hudItems.Add(new StandardHudItem());
            _hudItems.Add(new RevCounter(_vehicle.Chassis));
            _hudItems.Add(new Timer());
        }
Пример #3
0
        public RaceCompletedMode(CompletionType type)
        {
            _camera = new FixedChaseCamera(6.3f, 2.3f);
            _camera.FieldOfView = MathHelper.ToRadians(55.55f);
            _camera.RotationSpeed = 0.8f;
            _camera.MinHeight = 10;

            switch (type)
            {
                case CompletionType.Opponents:
                    MessageRenderer.Instance.PostHeaderMessage("Every opponent wasted!!", 10);
                    MessageRenderer.Instance.PostMainMessage("raceover.pix", 8, 0.7f, 0.003f, 1.4f);
                    SoundCache.Play(SoundIds.RaceCompleted, null, false);
                    SoundCache.Play(SoundIds.Clapping, null, false);
                    break;
                case CompletionType.Checkpoints:
                    MessageRenderer.Instance.PostHeaderMessage("All checkpoints passed!!", 10);
                    MessageRenderer.Instance.PostMainMessage("raceover.pix", 8, 0.7f, 0.003f, 1.4f);
                    SoundCache.Play(SoundIds.RaceCompleted, null, false);
                    SoundCache.Play(SoundIds.Clapping, null, false);
                    break;
                case CompletionType.Peds:
                    MessageRenderer.Instance.PostHeaderMessage("Every pedestrian murdered!!", 10);
                    MessageRenderer.Instance.PostMainMessage("raceover.pix", 8, 0.7f, 0.003f, 1.4f);
                    SoundCache.Play(SoundIds.RaceCompleted, null, false);
                    SoundCache.Play(SoundIds.Clapping, null, false);
                    break;
                case CompletionType.TimeUp:
                    MessageRenderer.Instance.PostMainMessage("timeup.pix", 8, 0.7f, 0.003f, 1.4f);
                    SoundCache.Play(SoundIds.OutOfTime, null, false);
                    break;
            }

            _camera.ResetRotation();
            _camera.RotateTo(MathHelper.Pi * 2);
            Engine.Camera = _camera;
        }
Пример #4
0
 public OpponentEditMode()
 {
     _opponentCamera = new FixedChaseCamera(6.3f, 2.3f);
     _opponentCamera.FieldOfView = MathHelper.ToRadians(55.55f);
     _fpsView = new FlyView(Race.Current.PlayerVehicle);
 }