Support the "rocket" command and similar stuff better

This commit is contained in:
Evenprime 2012-01-01 18:18:34 +01:00
parent f3df291f85
commit 7018858537

View File

@ -123,12 +123,16 @@ public class MovingEventManager extends EventManagerImpl {
data.horizFreedom *= 0.90; data.horizFreedom *= 0.90;
} }
if(data.vertVelocityCounter > 0) { if(data.vertVelocity <= 0.1) {
data.vertVelocityCounter--; data.vertVelocityCounter--;
}
if(data.vertVelocityCounter > 0) {
data.vertFreedom += data.vertVelocity; data.vertFreedom += data.vertVelocity;
data.vertVelocity *= 0.90; data.vertVelocity *= 0.90;
} else { } else {
data.vertFreedom = 0; // Counter has run out, now reduce the vert freedom over time
data.vertFreedom *= 0.90;
} }
// Get some data that's needed from this event, to avoid passing the // Get some data that's needed from this event, to avoid passing the