PH Force help

For questions about using Classic.

Post » Sat Nov 19, 2011 11:39 am

Hi all,

Situation.

When I hold 'D' down
-Sprite add force towards
-X=Sprite.X +3
-Y=Sprite.Y +3
-Force=1000

Is there a way to make the sprite speed(Force) stay the same without increaseing

.'.
Make the speed stay stable form Staring of hold to the ending of hold of the 'D' key
B
7
S
2
G
1
Posts: 193
Reputation: 1,745

Post » Sat Nov 19, 2011 11:44 am

Use force*timedelta and you'll get a steady supply of force, instead of tick dependant, possibly unstable one.

Also use timedelta for the +3 and such.
B
19
S
6
G
6
Posts: 1,101
Reputation: 5,646

Post » Sat Nov 19, 2011 11:47 am

I never knew what does time delta does

BTW tnx for help

Stalker2472011-11-19 11:47:24
B
7
S
2
G
1
Posts: 193
Reputation: 1,745

Post » Sat Nov 19, 2011 11:52 am

When I hold 'D' down
-Sprite add force towards
-X=Sprite.X +3
-Y=Sprite.Y +3
-Force=1000 * Timedelta
///
When I hold 'D' down
-Sprite add force towards
-X=Sprite.X * Timedelta
-Y=Sprite.Y * Timedelta
-Force=1000 * Timedelta

Does not work, what do you ment about the timedelta?
B
7
S
2
G
1
Posts: 193
Reputation: 1,745

Post » Sat Nov 19, 2011 12:08 pm

Ah, you mean stable movement of the object when the key is held. Well, you are using ADD force so the force keeps on stacking up, becoming stronger and stronger. Use SET force and it'll have the same speed (the one you set) and when the key is let go behave according to the physical properties of the object.
B
19
S
6
G
6
Posts: 1,101
Reputation: 5,646

Post » Sat Nov 19, 2011 12:22 pm

lol, Dumb me

Thanks
B
7
S
2
G
1
Posts: 193
Reputation: 1,745


Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 4 guests