Skip to content
This repository has been archived by the owner on Mar 6, 2018. It is now read-only.

Commit

Permalink
Make Priority settable for on StaticEventBinders (#187)
Browse files Browse the repository at this point in the history
The event engine has a concept of event binder priority, which it uses to determine what order the event binders should have when processing events.  This makes the Priority property settable for derived implementations of StaticEventBinder.
  • Loading branch information
hach-que committed Jun 3, 2017
1 parent e75e29d commit 8c13edb
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions Protogame/Events/StaticEventBinder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ public abstract class StaticEventBinder<TContext> : IEventBinder<TContext>
protected StaticEventBinder()
{
this._bindings = new List<Func<TContext, IEventEngine<TContext>, Event, bool>>();
Priority = 100;
}

protected interface IBindable<TEvent>
Expand Down Expand Up @@ -124,13 +125,7 @@ protected interface IBindableTo<TEvent, TTarget>
{
}

public int Priority
{
get
{
return 100;
}
}
public int Priority { get; set; }

public void Assign(IKernel kernel)
{
Expand Down

0 comments on commit 8c13edb

Please sign in to comment.