Home    LittleBigPlanet 2 - 3 - Vita - Karting    LittleBigPlanet 2    [LBP2] Help!
#1

Horribly Complicated Mover Problem (acceleration, deceleration, rotation & dampening)

Archive: 7 posts


Hey everyone,

I am in need of a logic expert to help with a complex "craft" I am creating for a vs. game. I have tried to simply the issue down to the exact problem but please let me know if you need more information.

The craft (a hologram circle) must behave in the following ways.

1. It must acceleration to a constant speed and continue at that speed forever

2. It must be capable of moving up and down on the screen via analog stick input

3. When there is no analog stick input, the craft must level out quickly (e.g. if your moving up at an angle, releasing stick should quickly correct the craft's trajectory back to straight / level

In addition to the above criteria, there are many more issues like limiting the rotation of the object and ensuring that up/down movement is sensitive to small changes in the analog stick (i.e. can't be a digital on / off). Don't worry about those for now though

The crux of the problem is that in order to make the craft travel smoothly, I need to use low acceleration on whatever moving device i'm using. Otherwise, the object wont acceleration slowly enough. I know i can set it to speed scale and use a timer but this is not an option because the craft sometimes encounters obstacles that slow it down. After passing through the obstacle the obstacle must acceleration back up to max speed. Using a timer like mentioned above results in the problem that the craft resets to a 0 speed once leaving an obstacle and thus does not move smoothly. Even a feedback loop used to set a minim speed via a timer to mover/speed scale system doesn't work because the hazards/obstacles are different sizes. Depending on how big the hazard is, the craft slows down more or less. Thus, using a bottom floor set with a feedback loop doesn't work because depending on the hazard size, it over or under estimates the speed it should start acceleration the craft from once it leaves the hazard.

Anyway, I have tried multiple simple and advanced mover setups, mover and signal limited joystick rotaters setups, and even followers on hologram poles.

Nothing works because to get any of these setups to have the ability to level out after the analog stick is released (see point 3), there must be at least 50% deceleration on the moving apparatus. As acceleration must be equal or greater than deceleration, this kills the crafts ability to acceleration slowly enough.


Any help is greatly appreciated!


EDIT: I have also tried using dampening to get the craft to maintain a straight path without stick input but again, it messes with the acceleration. It takes too much dampening to get the desired level off effect and that cancels out acceleration and results in a craft that moves at a constant speed even if you ramp the speed values on the mover to max. In contrast, if you set high acceleration and deceleration on the mover, it levels out nicely but no longer accelerates properly....
2011-07-22 01:23:00

Author:
Unknown User


3) Wire both L/R and U/D analog stick outputs into an inverted OR Gate hooked up to a Gyroscope.
Acceleration) Use an Advanced Mover with the analog stick as the Positive input to a Combiner into a timer. Set to speed scale. Use the NOT gate from above^ into the Negative input.
2011-07-22 02:25:00

Author:
Zero10100
Posts: 385


Ok, I should be able to help with all of you issues, but I don't have the time right now so I'll just do the rotation/up down issue ATM.
Firstly you'll need the mover set to use local space, then add a joystick rotator, a not gate in the top and up/down output from the stick in the side. Then just set acceleration and speed to suit your needs
2011-07-22 02:39:00

Author:
evret
Posts: 612


Thanks for the reply, I'm going to try that now but it seems similar to a setup I've already tested. I assume you were writing about a system with a rotater rather than just movers, let me know if I'm wrong

I will report back soon but in order to get the craft to go from moving up down to traveling straight fairly quickly (.5 sec), I will have to have high deceleration on the mover. Since acceleration must then be equal/greater to deceleration, even using a speed scale input will result in a craft that accelerates too quickly. I need it to acceleration for about 5 seconds.

Further, with the timer, how will it know what speed to start accelerating from once it has hit an obstacle and slowed down a little or a lot. Using just the movers acceleration without a speed scale input is preferred because when the craft leaves an obstacle it accelerates normally no matter how slow or fast it was traveling inside the obstacle. Thus, the timer always starts at 0 or some bottom limit value if set with an analog feedback loop. As a result, it moves too fast or too slow depending on how much/little the obstacle slowed down the craft.
2011-07-22 02:44:00

Author:
Unknown User


Ok, I should be able to help with all of you issues, but I don't have the time right now so I'll just do the rotation/up down issue ATM.
Firstly you'll need the mover set to use local space, then add a joystick rotator, a not gate in the top and up/down output from the stick in the side. Then just set acceleration and speed to suit your needs


Hey Evret,

I have tried that exact setup. It is the most simple / elegant way to limit the rotation of the craft and get it to behave basically how it should. However, the issue that I need high deceleration to level the craft quickly still applies. High deceleration requires high acceleration which then makes the craft accelerate too quickly. This can be avoided with a timer/speed scale, but then when the craft exits an obstacle (slower speeds in obstacles) it wont resume normal mode where it accelerates to a max speed. (see post above)

ZERO: There is also an issue with using a gyroscope and stick inputs because the gyro doesn't trigger until a minimum analog value is received. As someone suggested in another post, using a battery on a positional sequencer triggered by the stick and linked to the gyro can avoid that issue.

Thanks again everyone for the help.
2011-07-22 02:54:00

Author:
Unknown User


Get rid of the gyro, the joystick rotator will auto level if set how I described2011-07-22 06:44:00

Author:
evret
Posts: 612


Save the electronic trees for now... I have figured out a solution that works perfectly.

If anyone wants the answer, just let me know and ill take a pic and type it up.

Otherwise, thanks for the help
2011-07-22 06:45:00

Author:
Unknown User


LBPCentral Archive Statistics
Posts: 1077139    Threads: 69970    Members: 9661    Archive-Date: 2019-01-19

Datenschutz
Aus dem Archiv wurden alle persönlichen Daten wie Name, Anschrift, Email etc. - aber auch sämtliche Inhalte wie z.B. persönliche Nachrichten - entfernt.
Die Nutzung dieser Webseite erfolgt ohne Speicherung personenbezogener Daten. Es werden keinerlei Cookies, Logs, 3rd-Party-Plugins etc. verwendet.