Skip to content

Instantly share code, notes, and snippets.

@flushpot1125
Created June 11, 2016 00:58
Show Gist options
  • Save flushpot1125/535ec517d554a8ce4c8f928919358b98 to your computer and use it in GitHub Desktop.
Save flushpot1125/535ec517d554a8ce4c8f928919358b98 to your computer and use it in GitHub Desktop.
Part of Buttons.cs provided by Occipital Team
protected IEnumerator AssignGameEvent()
{
while (Manager._structureManager==null)
{
yield return new WaitForEndOfFrame();
}
//the manager has arrived, wait for instructions.
this.ButtonClickedEvent += Manager._structureManager.HandleButtonClickedEvent;
//set initial state on startup
this.gameState = Manager._structureManager.gameState;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment