Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public abstract class Controller
- {
- public event EventHandler LeftBegin;
- public event EventHandler LeftEnd;
- public event EventHandler RightBegin;
- public event EventHandler RightEnd;
- public event EventHandler UpBegin;
- public event EventHandler UpEnd;
- public event EventHandler DownBegin;
- public event EventHandler DownEnd;
- public event EventHandler JumpBegin;
- public event EventHandler JumpEnd;
- protected void OnLeftBegin(EventArgs e)
- {
- if (this.LeftBegin != null)
- this.LeftBegin(this, e);
- }
- protected void OnLeftEnd(EventArgs e)
- {
- if (this.LeftEnd != null)
- this.LeftEnd(this, e);
- }
- protected void OnRightBegin(EventArgs e)
- {
- if (this.RightBegin != null)
- this.RightBegin(this, e);
- }
- protected void OnRightEnd(EventArgs e)
- {
- if (this.RightEnd != null)
- this.RightEnd(this, e);
- }
- protected void OnUpBegin(EventArgs e)
- {
- if (this.UpBegin != null)
- this.UpBegin(this, e);
- }
- protected void OnUpEnd(EventArgs e)
- {
- if (this.UpEnd != null)
- this.UpEnd(this, e);
- }
- protected void OnDownBegin(EventArgs e)
- {
- if (this.DownBegin != null)
- this.DownBegin(this, e);
- }
- protected void OnDownEnd(EventArgs e)
- {
- if (this.DownEnd != null)
- this.DownEnd(this, e);
- }
- protected void OnJumpBegin(EventArgs e)
- {
- if (this.JumpBegin != null)
- this.JumpBegin(this, e);
- }
- protected void OnJumpEnd(EventArgs e)
- {
- if (this.JumpEnd != null)
- this.JumpEnd(this, e);
- }
- public abstract void Update(Single deltaTime);
- }
Advertisement
Add Comment
Please, Sign In to add comment