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

Logic problem (fairly simple)

Archive: 5 posts


Basically I'm trying to get a bouncepad that turns on temporarily when you press a button, which I thought would be simple as hell but it's messing up for some reason.

I have this:
http://i.imgur.com/lzmuz.png

The button activates a 1 hit counter, which then activates the timer and switches the toggle for the bounce pad on.

Once the timer is up it should switch the toggle back off and reset itself and the counter.

Anyone know where I might be messing up and how I can fix it? I'm thinking it might be an oversight in the way logic works on this game, or maybe I'm just derping.
2011-06-21 22:06:00

Author:
Dexiro
Posts: 2100


No need for the OR gate and the toggle switch. Remove them and just connect the output of the (1-shot) counter directly to the bouncepad. After all, the counter acts as the ON switch for as long as the timer is running.

Unless I am missing something here...

EDIT: you can even further simplify the setup (even though it becomes less easy to understand at first glance) by removing the 1-shot counter. Instead, you hook the button to the reset of the timer and set the timer to inverted (and the max count, so it won't have to count up first). You connect the output of the timer to the pad. The timer needs no other input.

Now, when you hit the button, the timer resets to 0 and starts counting. While it does that its inverted state sends out a positive signal, enabling the bounce pad. Once the timer is full again, the inverted state sets the pad to off.
2011-06-21 22:17:00

Author:
Antikris
Posts: 1340


You can get rid of the OR and the TOGGLE and just have the counter activate the bounce pad...you already have the timer reseting itself and the counter, so that's good. I haven't used a toggle...but it probably only flips it's state when it gets a signal.2011-06-21 22:18:00

Author:
fullofwin
Posts: 1214


Use just the timer, make it count down, and activate it with the button.

EDIT: Wait, I dunno if that'll work. Solutions above sound good though.
2011-06-21 22:27:00

Author:
SSTAGG1
Posts: 1136


No need for the OR gate and the toggle switch. Remove them and just connect the output of the (1-shot) counter directly to the bouncepad. After all, the counter acts as the ON switch for as long as the timer is running.

Unless I am missing something here...

EDIT: you can even further simplify the setup (even though it becomes less easy to understand at first glance) by removing the 1-shot counter. Instead, you hook the button to the reset of the timer and set the timer to inverted (and the max count, so it won't have to count up first). You connect the output of the timer to the pad. The timer needs no other input.

Now, when you hit the button, the timer resets to 0 and starts counting. While it does that its inverted state sends out a positive signal, enabling the bounce pad. Once the timer is full again, the inverted state sets the pad to off.

Ahh yeah I tried your first idea, seems to work perfectly! I'm using the timer as a visible display so I think the first idea would be the best. 2nd idea seems pretty clever, will use that in the future

Thanks for the help!
2011-06-21 22:44:00

Author:
Dexiro
Posts: 2100


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.