Home    LittleBigPlanet 1 - PSP - Tearaway -Run Sackboy Run    LittleBigPlanet 1    [LBP1] Help! [Archive]
#1

Speed controlled logic

Archive: 9 posts


I need some help... my current project is a survival challenge, so I want it to increase in difficulty as the player progresses. I plan to do this by looping through the same set of rooms, but increasing speed (by decreasing the amount of time the player is allowed in each room). But I find myself nowhere but tired and frustrated after several hours of work. Pistons don't work as I expected them to with variable speed settings, and attempting any sort of reset logic is even more folly.

What I'm attempting to do is provide a timer for the player (by way of a series of led lights that progress until your time is up). Then the whole system has to be reset so the player can proceed to the next room and the timer start back at the beginning. Once all the rooms have been played, the ENTIRE process needs to loop again, only this time, a bit faster. I have my looping logic built, the progression of lights as well. When I went to hook them up to a speed based mechanism is when I began to fail.

I was surprised (and dismayed) to see that:

a) Pistons do not move at a uniform pace, especially when set with a speed switch... they start out slow, then get up to speed in the middle then slow back down. Not noticeable at fast to moderate speeds, but you definitely see it when you slow it way down.

b) Even more frustrating is that the duration does not appear to be resettable. So even if I move my mag key out of range, and stop the piston (and/or use an additional winch to return it to the starting position), it will not go at the desired speed until it has re-synced itself, which may (and often does) take multiple cycles. This fact completely breaks my design. So I thought perhaps I needed to capture and emit the whole sequence, so it would be starting anew for each cycle. But even doing this, it appears to retain the timing of the previously emitted object(s) and stalls while it re-syncs.

After all this, I played for a bit with an emitter approach (and this may be the way I end up going, but it will be a nightmare), and some experiments with wobble and motor bolts hooked to speed switches. Now I'm just tired, confused and defeated.


Does anyone have any brilliant ideas / designs to work with looping speed settings and/or reset logic. I used rtm's reset demitter tool in my attempt to emit my logic. And it worked great, but emitting a new set of logic just didn't solve my problem.

Sorry for the wall of text here.
2009-11-03 06:54:00

Author:
v0rtex
Posts: 1878


I'm not sure how well this will work (with tweaking, etc), but this is an idea at least.
..its also somewhat hard to explain, so hopefully you can bear with me.

The logic device for this would use two parts:
1) A timer with multiple speed functions
2) Something to trigger the lights

The first device would look something like this (amazing artistry skills, i know):
http://i240.photobucket.com/albums/ff297/Burnvictim42/LBP/paintFTW.jpg
A piston would keep the magnetic key near the wheel (at its minimum length initially), the wheels rotation determining the time it takes for each light to come on. When you need to change the time, the outer wheel is dissolved, and the piston is moved forward. Since the wheel is smaller, the key has to travel less distance, and the time between lights will be less. Tweaking the diameters will let you figure out appropriate times. Motor bolts DO move at a uniform pace (as far as i know at least ). Set it up using a small emitter timed switch, so that the wheel will make a certain amount of rotations (equal to the number of lights) and then stop. Now, on to the second part.

EDIT: After doing a little play mode testing, i realized it would be simpler to have two seperate wheels, each with different speeds. Same setup, just the piston would be dragged between the two wheels of similar size instead of pushed into a wheel of a smaller diameter. The diameter works, but the difference between the times is rather insignificant.

The second device is somewhat of a *******ization of RTM's ordered input device. I've been using it extensively as of late with resettables. It should look something like this:
http://i240.photobucket.com/albums/ff297/Burnvictim42/LBP/paintFTW-2-1.jpg

This... is a bit more complicated. The three way switch set to directional controls a piston with a block. The block has a magnetic key, and will move rightward. The magnetic key switches are set to 180, and extend all the way to the right (so once the piston moves past it, it stays on). The three way switch is controlled via the use of winches and emitters. When the piston is supposed to move rightward, an emitter emits one key switch (which tugs one winch), when its supposed to move leftward, an emitter emits another(which tugs the other winch). In addition, for the rightward movement, there is an emitter on the block. This emits a block of dark matter in the position right after where the block would stop. This forms a wall, and makes it so you don't have to tweak the emitters too much, the piston just needs to move rightward, it will stop when it is supposed to. Each key switch is hooked up to a light, and as the block moves, the lights will turn on one by one.

Now, to integrate them. The key switch on the wheels will be set to one shot. Each time it is activated, it will 1 shot emit the block to stop the piston from moving too far, and a key switch to activate the 3 way switch moving it rightward. Every time the wheel makes a rotation, the next light will turn on via the ordered input. When its time to reset the mechanism, the player will do whatever resets it, and this will cause the other emitter to be 1 shotted, and move the piston all the way to the left so no switches are triggered.


so... yeah. Hopefully that was understandable, if not let me know and i'll whip up a tech demo.
2009-11-03 08:04:00

Author:
Burnvictim42
Posts: 3322


Thanks BV! I really think that might do the trick. Although after a chat session with Morgana last night, I think I may have a solution already in the works, that will be less sophisticated, but in the end, slightly easier to implement.

I already have in place a mechanism similar to the ordered input device (or output in this case) that you describe. That's the piston I was trying to control with a speed switch. I decided that I know how many times I will want to cycle through this and increase the speed (5 times is my initial, gut feeling), so I decided to just make that many separate pistons (each set to directional with slightly faster increments in speed), and just move the row of key switches to the active piston for each cycle.

But I like the design of the ordered input device, so I will probably steal it for advancing through the outer loop of my logic.

Thanks so much for the thoughtful, intuitive response. You da man!
2009-11-04 06:20:00

Author:
v0rtex
Posts: 1878


Sorry to bump my own thread, but I wanted BurnVictim to know that I've employed his solution almost verbatim, and it works brilliantly.

Thank you!!

(I'd show you, but I still have a long way to go before this one is finished. Stupid real life and all of it's distractions and responsibilities )
2009-11-21 18:13:00

Author:
v0rtex
Posts: 1878


Haha, well glad to hear it worked! I actually have been using this design myself for a certain LBPC the game project Lemme know when its out (whenever that is) i'd love to play it.2009-11-21 20:18:00

Author:
Burnvictim42
Posts: 3322


put a car on a track out of site use mag switch just experiment with diferent stuff2009-11-22 11:59:00

Author:
lbpholic
Posts: 1304


Have you read through the thread...?2009-11-22 12:03:00

Author:
ARD
Posts: 4291


Have you read through the thread...?

Well, in fairness ARD, advice like


just experiment with diferent stuff

Is always useful, no matter what the circumstances
2009-11-22 12:05:00

Author:
rtm223
Posts: 6497


Not necessarily rtm... for instance: experimenting with hallucinogens at the bus depot... not usually a good plan.
2009-11-22 15:13:00

Author:
v0rtex
Posts: 1878


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.