Skip to content

Instantly share code, notes, and snippets.

@seaders
Created October 31, 2015 22:16
Show Gist options
  • Save seaders/c8d1ad349cbaec842eea to your computer and use it in GitHub Desktop.
Save seaders/c8d1ad349cbaec842eea to your computer and use it in GitHub Desktop.
private IEnumerator _doFlash(bool first)
{
_mesh.colors32 = _darkColours[_colourIndex];
MainScript.log( "flashing to", this, MainScript.joinL(_mesh.colors32) );
yield return new WaitForSeconds(0.3f);
_mesh.colors32 = _colours[_colourIndex];
MainScript.log("flashing back to", this, MainScript.joinL(_mesh.colors32) );
yield return new WaitForSeconds(0.3f);
}
@seaders
Copy link
Author

seaders commented Oct 31, 2015

output:

flashing to (blue 9, 0) [RGBA(101, 0, 0, 255), RGBA(101, 0, 0, 255), RGBA(0, 0, 0, 255), RGBA(0, 0, 0, 255), RGBA(0, 0, 0, 255), RGBA(0, 0, 0, 255), RGBA(101, 0, 0, 255), RGBA(101, 0, 0, 255), RGBA(0, 0, 0, 255), RGBA(0, 0, 0, 255), RGBA(0, 0, 0, 255), RGBA(0, 0, 0, 255), RGBA(101, 0, 0, 255), RGBA(101, 0, 0, 255), RGBA(101, 0, 0, 255), RGBA(101, 0, 0, 255), RGBA(101, 0, 0, 255), RGBA(0, 0, 0, 255), RGBA(101, 0, 0, 255), RGBA(0, 0, 0, 255), RGBA(101, 0, 0, 255), RGBA(0, 0, 0, 255), RGBA(101, 0, 0, 255), RGBA(0, 0, 0, 255)]

flashing back to (blue 9, 0) [RGBA(255, 0, 0, 255), RGBA(255, 0, 0, 255), RGBA(127, 127, 0, 255), RGBA(127, 127, 0, 255), RGBA(127, 127, 0, 255), RGBA(127, 127, 0, 255), RGBA(255, 0, 0, 255), RGBA(255, 0, 0, 255), RGBA(127, 127, 0, 255), RGBA(127, 127, 0, 255), RGBA(127, 127, 0, 255), RGBA(127, 127, 0, 255), RGBA(255, 0, 0, 255), RGBA(255, 0, 0, 255), RGBA(255, 0, 0, 255), RGBA(255, 0, 0, 255), RGBA(255, 0, 0, 255), RGBA(127, 127, 0, 255), RGBA(255, 0, 0, 255), RGBA(127, 127, 0, 255), RGBA(255, 0, 0, 255), RGBA(127, 127, 0, 255), RGBA(255, 0, 0, 255), RGBA(127, 127, 0, 255)]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment