Loading...
Processing Forum
Recent Topics
All Forums
Screen name:
RobertC.
RobertC.'s Profile
2
Posts
4
Responses
0
Followers
Activity Trend
Last 30 days
Last 30 days
Date Interval
From Date :
To Date :
Go
Loading Chart...
Posts
Responses
PM
Show:
All
Discussions
Questions
Expanded view
List view
Private Message
Velocities with Seltar.Motion
[3 Replies]
19-Jul-2012 06:38 AM
Forum:
Contributed Library Questions
How do I get/set velocities with the seltar.motion library? I've tried every possibility that I can think of - ex:
mymotion.setVelocityX
mymotion.setVelX
mymotion.setXVel
mymotion.setXVelocity
None of the above have worked, never the less existed.
Thanks!
Collision between two rects
[4 Replies]
18-Jul-2012 05:08 PM
Forum:
Programming Questions
Does any body know how to detect and implement collisions between two 50x50 rects? I am using the selter.motion library with Processing 2.0a6. Here is my detection code:
boolean
bouncing() {
return
????;
}
And my bouncing code:
if
(!bouncing()) {
background
(128);
// all my code
}
else
{
mp.springTo((mp.getX() - mb.getX())*(-1), ((mp.getY() - mb.getY())*(-1)));
mb.springTo((mb.getX() - mp.getX())-1, ((mb.getY() - mp.getY())-1));
}
Thanks!
«Prev
Next »
Moderate user : RobertC.
Forum