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

spawn object from emitter - delete old one

Archive: 6 posts


Hi, I've searched but still clueless
So I have a button which spawns a object(random one), when I jump on the button again(after some time) I want to spawn a new one at the same place.
Problem is when I trigger the emitter again no new object will be spawned since the old object is still in place.
I don't know how long I'll need that object, so I can't give it a lifetime.

Best case scenario is user jumps button, object spawns, user does stuff at the object returns to the button, jumps it again, new object spawns, user does stuff at the object and so on....

I've tried setting max emitted to 2 and set delete oldest on when max reached but that doesn't work either, so how can I spawn a new object when the old one is still in place? Remind you that object is random

thx
2011-02-11 03:19:00

Author:
Unknown User


max emitted = Infinent
max emmited at one time = 1
delete oldest when limet reached = yes
hope this helps.
2011-02-11 03:21:00

Author:
dogcity999
Posts: 86


With the exception of dark/light matter and holo, objects cannot be emitted into an already occupied space (even if that space is occupied with an object emitted from the same emitter). So... you either need to destroy the object yourself before re-emitting, or you need to move the object out of the "emit-zone" (either immediately after it's emitted or right before emitting a new one).

I hope this helps.
2011-02-11 05:07:00

Author:
v0rtex
Posts: 1878


Thanks, that saved me a lot of time, I gave the object a player sensor to destroy it after it's done with the trigger area near the button, works exactly how I wanted it

One thing though, how can I reset the Randomiser?
I now hooked the Randomiser up to 15 objects(emitter) and set a counter so it gives me some but not all objects from the pool.
Additionally I have set the Randomiser to Pattern: Add and Input Action: Override Pattern so it gives me truly unique objects aka no object twice in a round, however I'm testing it and while it works one object will always be selected by the Randomizer(it will not be spawned anymore) so how can I reset it so that it can choose from the whole objects pool?
One solution would be to delete the Randomiser and create a new one but there's gotta be an easier way?!
2011-02-12 02:43:00

Author:
Unknown User


The Randomizer sucks, after it activates something. it doesn't turn off, except for lights. And the other problem, simple, The Creationator.
2011-02-12 02:59:00

Author:
Unknown User


hmm seems a simple reload did it, everything is back to default 2011-02-12 03:15: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.