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

Infinite Loop

Archive: 11 posts


Here is what I am trying to do. I am trying to build a way for a Statue to reappear if it gets destroyed. I want this to happen an infinite number of times. You would think that an emitter could do this, but it can't.

If you have the max out option on 1, lifetime on infinite, max emitted at infinite, and timing at .5 sec, you would think it would spit out one in .5 sec and stay until it was destroyed, but no. What happens is that it spits out one every .5 sec, the old one vanishing every time.

So here's what I did: I have an OR switch device. When either part of the statue is destroyed, it pushes a piston towards a switch. The switch turns on an emitter and then destroys the rest of the statue, the emitter, and the OR switch device. This whole contraption (the statue, the OR switch, and the emitter) is an object that is emitted by the emitter. This basically resets the whole thing. Unfortunately, this is only happens a finite number of times because at one point, the emitter emits an object whose emitter setting doesn't have an object to emit.

It's very complicated and makes my brain hurt. So does anyone have any idea of how to create an infinite loop so that I can destroy the statue an infinite number of times and I will always get another one.
2008-10-30 21:28:00

Author:
Voltiare
Posts: 646


Try setting a magnetic key on the statue being emitted, and the key switch right beneath it when it's emitted. Set it so that the key switch activates the emitter whenever the key is not in range. That way, whenever the statue is destroyed the key will get out of range and another one will replace it.2008-10-30 22:11:00

Author:
BassDeluxe
Posts: 984


Try setting a magnetic key on the statue being emitted, and the key switch right beneath it when it's emitted. Set it so that the key switch activates the emitter whenever the key is not in range. That way, whenever the statue is destroyed the key will get out of range and another one will replace it.The switch on the new statue will not be connected to the emitter. So instead of creating one statue, it will create one every .5 sec nonstop since nothing is telling it not to.

In order for the new statue to be connected to the emitter, the emitter has to emit another emitter and then destroy itself (by dissolving the material underneath it). The problem is that the object that you save to be emitted will have an emitter on it that doesn't have any object to be emitted. The reason is because you HAVE to create the object without the right settings because you can't have the emitter emit an object you don't have yet. TIME PARADOX.

So you can keep creating the object, and having the emitter emit the new object any number of times. Then the player can destroy the statue that number of times, but not an infinite number of times.
2008-10-30 22:34:00

Author:
Voltiare
Posts: 646


I totally thought of a time limit system where you had to get the object to the spot in a certain time before it disapears.. I think what i did is set up a grab switch that when you grab it, piston with a key at the end begins to move very slowely to the key switch, when it hits, the emitter turns off, and your object dissapears.2008-10-30 22:35:00

Author:
Unknown User


Erm, connect it to a switch :S LOL. I'm almost certain that works. Jump on the button a new one appears, don't jump on it, it stays there forever.2008-10-30 22:38:00

Author:
DrunkMiffy
Posts: 2758


I totally thought of a time limit system where you had to get the object to the spot in a certain time before it disapears.. I think what i did is set up a grab switch that when you grab it, piston with a key at the end begins to move very slowely to the key switch, when it hits, the emitter turns off, and your object dissapears.Nice. Does the piston go back when you are not grabbing it?


Erm, connect it to a switch :S LOL. I'm almost certain that works. Jump on the button a new one appears, don't jump on it, it stays there forever.I'll try it, but I don't like those ugly red buttons ruining the look of my level and I like the automatic approach. Unfortunately, you might be right in that it could be impossible to do it that way and player input might be needed.
2008-10-30 22:43:00

Author:
Voltiare
Posts: 646


does the statue drop down or what? i made a cake machine and it would place a cake down every 5 secs... the one that was in there would stay there until the button was pressed... if the item is in the way of the emmiter the emmiter does nto do anything2008-10-30 22:47:00

Author:
12454522412412
Posts: 779


The switch on the new statue will not be connected to the emitter. So instead of creating one statue, it will create one every .5 sec nonstop since nothing is telling it not to.


I think BassDeluxe had the right solution. The statue does not have a switch attached to it but rather the magnetic key is attached. The actual switch can be glued onto the ground.
2008-10-30 22:57:00

Author:
Unknown User


Actually, my method does work. I know as a fact because I just tried it. The only thing that matters with keys and key switches is that they are the same color. Nothing else matters. So the key on the statue being spawned will always stop the emitter from spawning more until it is destroyed, if you invert the key switch. And keep in mind, the key switch goes on the ground, not on the statue.2008-10-30 23:13:00

Author:
BassDeluxe
Posts: 984


Here is what I am trying to do. I am trying to build a way for a Statue to reappear if it gets destroyed. I want this to happen an infinite number of times. You would think that an emitter could do this, but it can't.

If you have the max out option on 1, lifetime on infinite, max emitted at infinite, and timing at .5 sec, you would think it would spit out one in .5 sec and stay until it was destroyed, but no. What happens is that it spits out one every .5 sec, the old one vanishing every time.

So here's what I did: I have an OR switch device. When either part of the statue is destroyed, it pushes a piston towards a switch. The switch turns on an emitter and then destroys the rest of the statue, the emitter, and the OR switch device. This whole contraption (the statue, the OR switch, and the emitter) is an object that is emitted by the emitter. This basically resets the whole thing. Unfortunately, this is only happens a finite number of times because at one point, the emitter emits an object whose emitter setting doesn't have an object to emit.

It's very complicated and makes my brain hurt. So does anyone have any idea of how to create an infinite loop so that I can destroy the statue an infinite number of times and I will always get another one.

Emitters work.

I just tried this with the exact same emitter setup and it works. The object I'm emitting is not vanishing at all until it moves from the area it was emitted to. Adjust where you emit the object and this problem should go away. This will be way easier than creating an elaborate switch setup.
2008-10-30 23:17:00

Author:
docpac
Posts: 601


Actually, my method does work. I know as a fact because I just tried it. The only thing that matters with keys and key switches is that they are the same color. Nothing else matters. So the key on the statue being spawned will always stop the emitter from spawning more until it is destroyed, if you invert the key switch. And keep in mind, the key switch goes on the ground, not on the statue.Ah, on the ground. So you would just set the range at some wide setting. I don't know why I didn't think of that since it is MUCH simpler. Oh well, you live and learn.2008-10-31 08:20:00

Author:
Voltiare
Posts: 646


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.