Vertical Space Shooter Template. Speed adjustment question?

Get help using Construct 2

Post » Thu Feb 27, 2014 5:54 pm

Hey everyone.

In the Vertical Space Shooter Template the speed of the player is controlled by the event saying that if the player is in touch the object will move towards the touched position at 300 *dt per pixel. There is a co-event preventing the unpleasant jittering if the player is touching the place where the object currently is. If you try to increase these numbers, the speed of the player's movement increases as well. The problem is, the movement of the object becomes very blocky.

To give an example, if you increase the value of 300 *dt ppx to 1300 * dt ppx the object moves very fast, but only in small blocks. How do you fix this, how do you make the object move as smoothly as possible.
B
9
S
1
Posts: 51
Reputation: 639

Post » Thu Feb 27, 2014 7:28 pm

some values are going to be too large to move smoothly, *dt is framerate independent, so it can move regardless of the frame rate, which means at high speeds things are going to skip visual pixels on the screen since the frame rate is not drawing fast enough to show each movement between refreshes.
B
49
S
12
G
10
Posts: 1,833
Reputation: 14,573

Post » Thu Feb 27, 2014 9:54 pm

Interesting.

I tested the game on nexus 4 and the movement is quite blocky. However, if I put my finger on the bottom of the screen, under the game layout, the controls become smooth as silk. Any explanation to this?
B
9
S
1
Posts: 51
Reputation: 639

Post » Thu Feb 27, 2014 10:50 pm

No idea on that one, unless there is an issue in the events that is causing it to jitter like that, perhaps multiple touches registering, or triggering multiple events...
B
49
S
12
G
10
Posts: 1,833
Reputation: 14,573

Post » Fri Feb 28, 2014 12:24 am

Ok, I will be doing further tests and will inform you on my findings.

Thank you for your help nonetheless :)
B
9
S
1
Posts: 51
Reputation: 639


Return to How do I....?

Who is online

Users browsing this forum: Lancifer and 4 guests