Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

java key pressed

//setting key to pause a meathod


void keyPressed() {
  if (key == 'p' || key == 'p') {
    paused = !paused;
  }
}

//use to stop draw(), move(),ect.
  if(!paused){
}
 
PREVIOUS NEXT
Tagged: #java #key #pressed
ADD COMMENT
Topic
Name
3+2 =