Physics Question: Rotation and Drift

Get help using Construct 2

Post » Sat Dec 07, 2013 11:35 pm

EDIT: Figured out my silly mistake right after I posted this. LMB click is a trigger and running Every Tick as a sub-event make the tick event only fire once.

If I were to give a circular object Physics and have it set to apply a Force towards another target object on mouse click. I also apply a Torque at the same time to give it rotation.

What I would like to do after this point is have the Physics object drift to the left or right based on it's rotation and angular velocity. Imagine a spinning top given forward momentum that gradually veers to the right when spinning clockwise, with the amount veered based on the current speed it is spinning at.

I have everything working as in the first paragraph, but I've tried numerous methods to get the object to drift without success. For Example:

--> On LMB: Object | Apply Physics Force 10 toward (target.x, target.y) and Apply Physics Torque 50

Sub Events:

A)    Every Tick: Object | Move object.Physics.AngularVelocity at angle 0

B)    Every Tick: Object | Apply Physics impulse (object.Physics.AngularVelocity,0)


EDITJH12013-12-08 00:01:17
B
7
S
3
G
3
Posts: 22
Reputation: 2,385

Return to How do I....?

Who is online

Users browsing this forum: koops and 7 guests