package com.Tutorial 
{
    import com.adamatomic.flixel.*;
	/**
	 * ...
	 * @author Stephen Lavelle
	 */
	public class Presents extends FlxState
	{
		private var _introTimer:Number;
		private var _pressed:Boolean;
		private var _gameOver:Boolean;
		
		public function Presents():void
		{
			_introTimer = 2;
			_pressed = false;
		
			this.add(new FlxText(0, 160, FlxG.width, 80, "increpare presents", 0xffc35752, null, 32, "left")) as FlxText;			
		}
		
		
        override public function update():void
		{
			_introTimer -= FlxG.elapsed;
			
			if (FlxG.justPressed(FlxG.A || FlxG.B))
			{
				_pressed = true;
			}
			
			if (_introTimer <= 0 || (_pressed && _introTimer<1.5))
			{
				FlxG.switchState(MenuState);
			}

			super.update();
		}		
	}
}