示例#1
0
文件: Level2.cs 项目: aenario/Squick
        public Level2(KinectInterface gameInput)
        {
            _levelBackground = ResourceManager.tex_background_level2;
            squick = new JumpingSquick(gameInput);
            squick.Pos = new Vector2(400, 800);
            squick.Speed = new Vector2(0,-600);
            toBeDestroy = new List<Entity>();

            activeBranch = new Branch(gameInput);
            oldBranches = new List<Branch>();
            cameraOffset = 0;

            fadeEffect = new Fade();

            gauge = new Gauge(new Rectangle(30, 50, 10, 500), goal, Color.BurlyWood, Color.Gold);
            message = new Message("Training time !", new Vector2(20, 220), 2.0f, Message.DISPLAY_LBL, 50);
            hc = new HandCursors();
        }
示例#2
0
文件: Fade.cs 项目: aenario/Squick
        public void Start(Fade.EFFECT effect, Color color, double durationTime)
        {
            // Reset global state
            _hasFinished = false;
            _isRunning = true;
            _step = 0; // Reset (100 = finished)

            // Default parameters
            _currentEffect = effect;
            if (effect == EFFECT.FADE_OUT)
                _transparency = 1.0f; // -> 0
            else
                _transparency = 0.0f; // -> 1 (Fade_in)
            _durationTime = durationTime;

            _currentColor = color;

            // Compute step
            _interval = _durationTime / 100;
        }
示例#3
0
文件: Level1.cs 项目: aenario/Squick
        //private Player _squick;
        public Level1(KinectInterface gameInput, bool modeAdventure = false)
        {
            _levelBackground = ResourceManager.tex_background_level1;
            _modeAdventure = modeAdventure;

            _bombEffect = new Fade();

            _HUD_score = new Score(new Vector2(10,0));
            _backToMenu = new TextButton("Menu", new Vector2(690, 10));

            squick = new DizzySquick(gameInput);
            squick.Pos = new Vector2(400, 400);

            _gameEventMessage = new Message("Ready?  Set...  Go!", new Vector2(20, 220),2.0f,Message.DISPLAY_LBL,250);
            _gameScoreMessage = new Message("",new Vector2(10,160),1.0f,Message.DISPLAY_LBL,1000);

            // Level score
            _score = 0;
            _bonusChain = 0;
        }