Skip to content

Instantly share code, notes, and snippets.

@firepunch
Created May 6, 2017 15:14
Show Gist options
  • Save firepunch/80c4508a04d6d0d21fd51d2450d621a9 to your computer and use it in GitHub Desktop.
Save firepunch/80c4508a04d6d0d21fd51d2450d621a9 to your computer and use it in GitHub Desktop.
Processing function - It is executed automatically when a key is pressed.
void keyPressed() {
if(key =='[') {
currentColumn--;
if(currentColumn < 0) {
currentColum = currentCount - 1;
}
} else if (key == ']') {
currentColumn++;
if(currentColumn == columnCount) {
currentColumn = 0;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment