Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

p5js left mouse click

if (mouseButton === LEFT) { // LEFT MOUSE BUTTON
  //do stuff...
}
else if (mouseButton === RIGHT) { // RIGHT MOUSE BUTTON
  //do other stuff...
}
else if (mouseButton === CENTER) { // MOUSE WHEEL
  //do other stuff...
}
 
PREVIOUS NEXT
Tagged: #left #mouse #click
ADD COMMENT
Topic
Name
1+8 =