-
hey,
i'm too busy for a real discussion ;(
if you want to let the user rotate the whole bike, one way to do is would be to displace the two main bike particles, and/or displace all of the bike particles. (i don't know which would work best).
the direction of displacement would be perpendicular to the main bike axis. so, once you have the main axis as a unit vector ax,ay, displace the two axis particles perpendicular to the main axis. if the two axis particles are pa and pb:
pa.x += amt*ay;
pa.y += amt*-ax;
pb.x -= amt*ay;
pb.y -= amt*-ax;
where amt is the amount of spin.
note that moving the particles perp. to their axis will violate the stick constraint between them.. so don't move them by much.
sorry if this explanation sucks, i'm in a hurry
raigan
-
yeah.. i finally able to add the rotation, altough i need a few parameters such as rotation lock cause I don't think one can easily rotate a vehicle
I'm trying to get the angular velocity of the particle that way I can rotate the vehicle more realistic.
anyway.. I notice in your particle system is that when the vehicle hit's the ground so hard, the system will break resulting the particle to be displaced, is there a way to make it more rigid ??
-
Professional Air Guitarist
Low gravity + low friction = high flying
http://www.gotcool.com/misc/bike.swf
-
This stuff is really neat.
Frag: do you mind posting the .fla?
-
Finally after messing around with the code I can make my own..
try : www.iplayallday.com/test/biketest.html
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|