public MainGameScene(int restingHeartRate, bool heartCore) { this.Entities = new List<Entity>(); ClockManager = new Timing.ClockManager(); m_Player = new PlayerThing(this, restingHeartRate); m_BulletManager = new BulletManager(this); m_BugManager = new BugManager(this); // m_PingManager = new PingManager(this); m_PingManager = new NewPingManager(this); m_BackgroundTexture = HeartAttack.theGameInstance.Content.Load<Texture2D>("background"); m_Ripple = HeartAttack.theGameInstance.Content.Load<Effect>("RippleShader"); m_PingLengthsParameter = m_Ripple.Parameters["pingLengths"]; m_Ripple.Parameters["Viewport"].SetValue( new Vector2(HeartAttack.theGameInstance.graphics.GraphicsDevice.Viewport.Width, HeartAttack.theGameInstance.graphics.GraphicsDevice.Viewport.Height)); m_ShaderRenderTarget = new RenderTarget2D (HeartAttack.theGameInstance.graphics.GraphicsDevice, HeartAttack.theGameInstance.graphics.GraphicsDevice.PresentationParameters.BackBufferWidth, HeartAttack.theGameInstance.graphics.GraphicsDevice.PresentationParameters.BackBufferHeight); m_ShaderTexture = new Texture2D( HeartAttack.theGameInstance.graphics.GraphicsDevice, HeartAttack.theGameInstance.graphics.GraphicsDevice.PresentationParameters.BackBufferWidth, HeartAttack.theGameInstance.graphics.GraphicsDevice.PresentationParameters.BackBufferHeight, true, m_ShaderRenderTarget.Format ); director = new AIDirector(m_Player, heartCore); }
public Timer(ClockManager manager, float duration, bool autoStart, EventHandler complete) : base(manager) { Duration = duration; Complete += complete; if (autoStart) Start(); }
public SpriteAnimation( ClockManager manager, List<Texture2D> frames, Texture2D defaultFrame, Sprite sprite, float frameLength) : base(manager) { Frames = frames; Sprite = sprite; FrameLength = frameLength; DefaultFrame = defaultFrame; this.RepeatCount = frames.Count - 1; this.BeginOffset = 0.01; }
public Timer(ClockManager manager) : base(manager) { }
protected Clock(ClockManager manager) { Duration = 1.0; // 1 sec State = ClockState.Stopped; ClockManager = manager; }