|
Azarii Fugazi
Registered User
Join date: 26 May 2006
Posts: 4
|
08-08-2006 23:57
Okay. Is their anyway to keep objects attached. But when someone or something bumps into the objects they break apart? Example: The carnival game where you have to throw a ball at the stacked bottles and knock them down.
I want something like that but do not want to have to re-stack the individual objects everytime. I just want to rez the whole thing and have it so it can get knocked apart after rez.
Is their a script that does this?
|
|
Xixao Dannunzio
Owner, X3D Enterprises
Join date: 20 Mar 2006
Posts: 114
|
08-09-2006 01:04
I would suggest this:
- Create your objects, and stack them how you want - Enable Physics on everything - Select them all, then Take them as a group into your inventory - Setup a base for them to sit on, and script a listener that listens for a specific key command, and rezzes the group when it hears it, after (x) seconds delay - Have the front-most object speak that command when it detects a collision, and set a timer on itself to run llDie() after (x) seconds - Have a listener in the remaining objects to also run llDie() when the key word is heard
The result: - Objects are stacked - Something hits the objects, they move with physics - After (x) seconds, the original set deletes itself, and a new one is rezzed in its place
Just a thought... try it and see how it works out.
|
|
Hewee Zetkin
Registered User
Join date: 20 Jul 2006
Posts: 2,702
|
08-09-2006 11:55
Just make the objects non-physical and then turn on physics via 'llSetStatus()' on each at the appropriate time. You may need to give each one an appropriate push if you change the status based on a collision event (unless perhaps you put an 'llVolumeDetect()' object around the other prims and hope the collision hits them after you change the status?). You'd just have to expriment with that.
One way would be to link all the prims and then use 'llBreakAllLinks()', and have a 'changed()' event on each prim set the physical status. The downside of this one is that all the, "individual objects," would have to be single-prim objects.
Another idea is to have the original object rez one or more physical objects and then die itself (the script delays would have to be carefully managed by distributing work with link messages).
|