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

Logic trouble: Exclusive check

Archive: 3 posts


Hi there, I'm designing a level with the tipical points coffins/boxes that the user can activate (with R1) to open them, but I'm facing some trouble in the desing of the logic for the prize system. The problem is the next:

Some of the boxes will have a "? " symbol on it (and there will be at least 3 of them on the level).

If NONE of the boxes with the ? symbol have been activated, the first to do so will emit a special item via an emiter.

If ONE or more than one of the boxes have been activated, then the box will emit a monster creature.

So, the logic desing I need is one that checks if some box has been activated, if false, then emit a prize, otherwise emit a foe.

Any help with this?

Thanks.
2010-12-30 16:40:00

Author:
Gryphus
Posts: 5


The simplest way to do this is probably to create the following:

Make a U shape of dark matter, preferably grid aligned. Inside that you will want to stack three squares of dissolve on top of one another. On top of the dissolve, place a single glass square on top of those and place a mag key on them.

Hook up each of the grab switches to one of the pieces of dissolve, so that when it is grabbed, the dissolve dissolves and the glass falls down by one square. Using this the position of the glass will be dependent on the number of grab switches that have been grabbed and you can use the position to trigger the correct action.


This assumes that if you grab a box again, then it will do nothing.
2010-12-30 17:14:00

Author:
rtm223
Posts: 6497


Thanks, that it a simple yet effective solution.

The boxes dissapear after being activated, so you can't activate one single box twice. But thanks to your idea (and modifiying it a bit) I've come to a solution. I post a scheme here for further reference of other forum users:

(Check the image first):
http://img258.imageshack.us/img258/4144/exclusivechecker.jpg
The Red mag key is the first output, connected to the emitter on the boxes which will give the good prize when the box is activated via R1 Switch (the same switch that dissolves the BOX).

That R1 switch is also connected to the dissolve material. The same to the other 2 boxes, and ALL of them are connected to the dissolve material on the bottom.

Last, the cyan mag key activates the other emiter on the boxes, which will spawn a enemy creature.

How this works: If none of the boxes has been activated, the first to do so will use the red key-connected emiter, and 2 of the green blocks will disolve (the one on the bottom, and the assigned to the respective box. Now the red emitter will deactivate, and the cyan will be on "standby", waiting for the R1 switch of any of the other 2 remaining boxes to be used.

Now, if the player activates any of that other 2 boxes, is the cyan emitter the one that will activate, spawning a monster instead of a prize.

Maybe someone can help with a better or more simple desing, but I hope you can find this useful, because it can be used for any numer of variables, it's basically a "mecanical" OR gate.

Thanks again for your help giving me the original idea.
2010-12-30 17:49:00

Author:
Gryphus
Posts: 5


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.