We are about to switch to a new forum software. Until then we have removed the registration on this forum.
n/a
if(p.x<0) // changes direction
https://forum.processing.org/two/discussion/15473/readme-how-to-format-code-and-text#latest
https://forum.processing.org/two/discussion/22759/i-have-a-current-code-but-i-need-to-make-the-outer-squares-move-please-help#latest
Four days. Zero effort on your own.
Edit your post (gear icon in the top right corner of your post), select your code and hit ctrl+o to format your code. Make sure there is an empty line above and below your code.
Kf
For a general overview of collision detection algorithms in Processing -- it sounds like you are bouncing balls off of rectangles -- see:
Cange randomDirection
Eg
randomDirection.x=-1 * randomDirection.x;
from here:
https://forum.processing.org/two/discussion/22759/i-have-a-current-code-but-i-need-to-make-the-outer-squares-move-please-help
FIX THE CODE FORMAT, IT IS UNREADABLE.
Answers
if(p.x<0) // changes direction
https://forum.processing.org/two/discussion/15473/readme-how-to-format-code-and-text#latest
https://forum.processing.org/two/discussion/22759/i-have-a-current-code-but-i-need-to-make-the-outer-squares-move-please-help#latest
Four days. Zero effort on your own.
Edit your post (gear icon in the top right corner of your post), select your code and hit ctrl+o to format your code. Make sure there is an empty line above and below your code.
Kf
For a general overview of collision detection algorithms in Processing -- it sounds like you are bouncing balls off of rectangles -- see:
Cange randomDirection
Eg
from here:
https://forum.processing.org/two/discussion/22759/i-have-a-current-code-but-i-need-to-make-the-outer-squares-move-please-help
FIX THE CODE FORMAT, IT IS UNREADABLE.