Skip to content

Instantly share code, notes, and snippets.

@gastrop0d

gastrop0d/crit4.cs Secret

Created Feb 9, 2018
Embed
What would you like to do?
public class StunnedAction : TimedAction
{
public void Begin()
{
QueryDispatcher.SubscribeToBool(QUERY_ADVANTAGE_GRANTED, GetAdvantage);
/* do other stuff like trigger a stunned animation... */
}
public void End()
{
QueryDispatcher.UnsubscribeFromBool(QUERY_ADVANTAGE_GRANTED, GetAdvantage);
/* do other stuff like reset our animation... */
}
BoolResult GetAdvantage( GameObject subject )
{
return new BoolResult( subject == _actor, true );
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.