Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

How does it work?!?!

Dan Medici
Registered User
Join date: 25 Jan 2004
Posts: 132
10-30-2004 09:08
For any of you have seen, purchased, or used Sion Zaius' shield, it basically rezzes a small shielding object between the owner and any incoming projectiles. First I assumed he is just using a sensor, I tried that, but it still didn't calculate fast enough. It detected the object when it was about a third or a fourth of a meter away from me (I just used a simple llSay and took out all calculations that might slow it down in my sensor). Next I thought, maybe he's using volume detect, but that was even slower. As long as he's not using any top secret tricks in LSL, can anyone explain any reasonable way he can be doing this? I mean, When I'm 20 meters above someone using the shield, and I fly down 10 meters at him, the shield already rezzes and picks me up. I can't figure it out.

Note: The script isn't just a spherical shield that follows the user, if I explained it poorly. I'm pretty sure it's an attachment that detects objects that are moving towards the owner and rezzes the shield in between. When I used my sensor, I calculated the object's forward speed, and if it was greater than 5, I rezzed the shield at the quarter point (midpoint of the midpoint) between the user and the objec'ts detected position. Even when I took out the calculations of the quarter point, the sensor still picked the object up way too late (I tried sensoring at 0.1 and 0.01 speeds)
Moleculor Satyr
Fireflies!
Join date: 5 Jan 2004
Posts: 2,650
10-30-2004 09:25
Maaaaaaagic.
Dan Medici
Registered User
Join date: 25 Jan 2004
Posts: 132
10-30-2004 10:12
Thanks. : o P
Moleculor Satyr
Fireflies!
Join date: 5 Jan 2004
Posts: 2,650
10-30-2004 11:24
Welcome!
Dan Medici
Registered User
Join date: 25 Jan 2004
Posts: 132
10-30-2004 11:31
Come on... no ideas?
Moleculor Satyr
Fireflies!
Join date: 5 Jan 2004
Posts: 2,650
10-30-2004 11:34
Buy it and look inside, see for yourself?

I'm not so sure any scripter here would be willing to reverse engineer someone's product out in the open like this, or even privately, for someone else. It'd be equivilent to figuring out your password or something and then sharing it.
Dan Medici
Registered User
Join date: 25 Jan 2004
Posts: 132
10-30-2004 12:26
That's true. The script is closed source so I couldn't figure out that way. I'm not trying to immitate his product really... I need a similar technique for a script I am making so I was wondering how it was possible. I've found using llVolumeDetect in a big sphere around the owner works well but its still not fast enough to stop fast-moving projects.
Cross Lament
Loose-brained Vixen
Join date: 20 Mar 2004
Posts: 1,115
10-30-2004 12:33
From: Dan Medici
For any of you have seen, purchased, or used Sion Zaius' shield, it basically rezzes a small shielding object between the owner and any incoming projectiles. First I assumed he is just using a sensor, I tried that, but it still didn't calculate fast enough. It detected the object when it was about a third or a fourth of a meter away from me (I just used a simple llSay and took out all calculations that might slow it down in my sensor). Next I thought, maybe he's using volume detect, but that was even slower. As long as he's not using any top secret tricks in LSL, can anyone explain any reasonable way he can be doing this? I mean, When I'm 20 meters above someone using the shield, and I fly down 10 meters at him, the shield already rezzes and picks me up. I can't figure it out.

Note: The script isn't just a spherical shield that follows the user, if I explained it poorly. I'm pretty sure it's an attachment that detects objects that are moving towards the owner and rezzes the shield in between. When I used my sensor, I calculated the object's forward speed, and if it was greater than 5, I rezzed the shield at the quarter point (midpoint of the midpoint) between the user and the objec'ts detected position. Even when I took out the calculations of the quarter point, the sensor still picked the object up way too late (I tried sensoring at 0.1 and 0.01 speeds)


I'd guess it's a large, spherical attachment surrounding the user, using collision_start() and checking the speed of the colliding object. If you make the attachment big enough, I imagine it'd have time to rez something between the incoming projectiles and the hapless target. ^^

Mind, there's not much point to shields anyway. It's not like anything can stop phantom bullets. Not even using the llVolumeDetect() trick to make your own av phantom will protect you. :P
_____________________
- Making everyone's day just a little more surreal -

Teeple Linden: "OK, where did the tentacled thing go while I was playing with my face?"
Dan Medici
Registered User
Join date: 25 Jan 2004
Posts: 132
10-30-2004 13:26
That's the technique I'm using now. It's not fast enough for speedy projectiles.

I'm not really doing this because I NEED a shield, I was just very curious about how he rezzed something so quickly.
Francis Chung
This sentence no verb.
Join date: 22 Sep 2003
Posts: 918
10-30-2004 13:53
From: Moleculor Satyr
I'm not so sure any scripter here would be willing to reverse engineer someone's product out in the open like this, or even privately, for someone else. It'd be equivilent to figuring out your password or something and then sharing it.


You're joking, right? Figuring out how someone works and ripping off someone's password are two different things entirely.

Knowledge is not a zero-sum game. We're all richer for understanding how things work.

Knowing a trick should be free. Making something that works is your own property. There's no patent law in SL for a reason.

Dan, as far as your questions go, I'll share some of my observations with you.

Sion's shield, I think, was pretty clever, given the constraints of SL. For one thing, I suspect he uses multiple sensor scripts, each responsible for a different arc around the avatar. (eg. in front, above, above-front-left)

Second thing is I don't think he actually calculates the intersection points. He makes some pretty rough approximations. My guess is just that he checks the dot product of a vector away from the avatar and the velocity of the projectile. If it's less than, -5, say, rez a shield.

I actually know a few more tricks than I'm letting on, because some other shield-makers have shared their techniques with me. I treat that as priviledged conversation. Talk to Reitsuki Kojima and Adam Zaius, maybe they'll share some tips with you :)

One thing Adam Zaius did mention in a forum post way back when, was that he found that rezzing stuff isn't as effective as having a follower object. Something about 18 hollowed, linked invisible cubes following you around or something like that.
_____________________
--
~If you lived here, you would be home by now~
Dan Medici
Registered User
Join date: 25 Jan 2004
Posts: 132
10-30-2004 20:18
Thanks so much for the pointers Francis :)

As far as Sion's shield, I actually had the idea also of using different arcs using volume detect, I found that was most effecient. However, Sion Zaius' script must use a sensor, as I just looked at someone using it and there were no objects following them or attached to them. Any ideas about that?

Edit: As I said before, I tried a test object with an llSay in the sensor event, sensoring at a rate of 0.01 seconds, with a range of 10. Does anyone know why the object gets LESS than a half meter away from me before the say occurs? Is it the llSay function or is it sensor being slow? I'm doing it in a sim with minimal lag. Seeing as I think I have deducted above that Sion is using a sensor, I don't know how his works so much quicker than mine.
Zuzi Martinez
goth dachshund
Join date: 4 Sep 2004
Posts: 1,860
10-30-2004 22:06
well i'm pretty sure llSay has a built in delay. tried link messages?
Sion Zaius
newbie since 2003
Join date: 25 Dec 2003
Posts: 37
11-05-2004 02:31
cool thread :eek:
_____________________
scripting is like sex. so do not interrupt me! :eek:
Rickard Roentgen
Renaissance Punk
Join date: 4 Apr 2004
Posts: 1,869
11-05-2004 10:08
From: Cross Lament
I'd guess it's a large, spherical attachment surrounding the user, using collision_start() and checking the speed of the colliding object. If you make the attachment big enough, I imagine it'd have time to rez something between the incoming projectiles and the hapless target. ^^

Mind, there's not much point to shields anyway. It's not like anything can stop phantom bullets. Not even using the llVolumeDetect() trick to make your own av phantom will protect you. :P


nope, any attachment is phantom and does not detect collisions made on the attachment. The collision start event will be triggered when the first bullet hits the av.
_____________________
Rickard Roentgen
Renaissance Punk
Join date: 4 Apr 2004
Posts: 1,869
11-05-2004 10:11
oh, and the less mass a shield prim has the faster it will rez, and allow the next one to be rezzed.
_____________________
Ming Chen
Here since 0.4.1!
Join date: 3 Sep 2003
Posts: 524
01-22-2005 10:13
there is a function that is in the archives somewhere that checks to see if something is coming toward you. thats how it works...
_____________________
Jesrad Seraph
Nonsense
Join date: 11 Dec 2004
Posts: 1,463
01-22-2005 11:34
Nice tricks. I think using a following invisible block centered around the owner, that rezzes the physical shield itself when colliding with something going towards owner, might work fast enough.
_____________________
Either Man can enjoy universal freedom, or Man cannot. If it is possible then everyone can act freely if they don't stop anyone else from doing same. If it is not possible, then conflict will arise anyway so punch those that try to stop you. In conclusion the only strategy that wins in all cases is that of doing what you want against all adversity, as long as you respect that right in others.
Cross Lament
Loose-brained Vixen
Join date: 20 Mar 2004
Posts: 1,115
01-22-2005 13:13
From: Rickard Roentgen
nope, any attachment is phantom and does not detect collisions made on the attachment. The collision start event will be triggered when the first bullet hits the av.


Wow, was I slow to answer this one! You are right, of course. I sit corrected. :D
_____________________
- Making everyone's day just a little more surreal -

Teeple Linden: "OK, where did the tentacled thing go while I was playing with my face?"
lmho Impfondo
Registered User
Join date: 7 Apr 2005
Posts: 31
04-13-2005 22:09
You only need one sensor, unless you want faster rezzing of shields. I've made shield agitators before and there is a time cap on the shields being rezzed, leading me to believe there is only one prim rezzing the shields. I've made prototype shieldmakers using many different arcs, but it isnt faster or more reliable than one sensor, one prim. Sion is very clever to make his shields rez so quickly , but the sion shield isnt invincible. Run some tests with an object rezzing spheres at you at faster and faster speeds, you will get hit eventually.

EDIT: Oh god I'm terribly sorry for bumping this dinosaur of a thread. I searched for something and this came up on the front page.