Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

scripts within a HUD

Tere Karuna
Registered User
Join date: 4 Jul 2004
Posts: 159
08-30-2006 20:03
Please excuse these newbie questions; ya would think as long as Ive been in SL I would have learned scripting before now.

Few things Im wonder...

I know can make "push buttons" to go into a HUD. Can animations be triggered by these buttons; and if so how fast will the AV react to the event?

Im assuming that a delay can be scripted into the buttons kinda like a "refresh timer" before they can be activated again?

Is it a problem to instead of "pushing" the button, one key can be hit (like F1) to activate the button?

I got a build in mind and before try to hire a scripter, wanted make sure its possible so they dont rolls their eyes at me.
_____________________
"ooohhhh we didnt know what we had till it was gone;
they paved secondlife and put up a shoping mall,
oooooo, ba ba ba....."
Osgeld Barmy
Registered User
Join date: 22 Mar 2005
Posts: 3,336
08-30-2006 21:43
usefull url's, this is a pretty veuge question, so heres some reading ...

How to make buttons without a script in each button.
/15/df/69401/1.html

llRequestPermissions
http://secondlife.com/badgeo/wakka.php?wakka=llRequestPermissions

From: someone
Invokes the run_time_permissions event when agent accepts or rejects the requested permissions.


run_time_permissions
http://secondlife.com/badgeo/wakka.php?wakka=run_time_permissions

animation
http://secondlife.com/badgeo/wakka.php?wakka=animation

example
/54/7b/27543/1.html

short list

yes

sorta, mostly load and lag of the sim / connection (expect seconds as your lowst form, maby like 10- 60 +seconds .. plz)

its expensive

:)
Yumi Murakami
DoIt!AttachTheEarOfACat!
Join date: 27 Sep 2005
Posts: 6,860
08-31-2006 06:33
From: Tere Karuna

I know can make "push buttons" to go into a HUD. Can animations be triggered by these buttons; and if so how fast will the AV react to the event?


Yes. How fast the AV reacts will depend on the lag in the sim at the time, but in the best case it will be less than a second.

From: someone

Im assuming that a delay can be scripted into the buttons kinda like a "refresh timer" before they can be activated again?


Yes.

From: someone

Is it a problem to instead of "pushing" the button, one key can be hit (like F1) to activate the button?


I believe the only way to do this is to make the script listen for a command, and then create a gesture that issues that command, and then bind it to a key. But no, SL really, really doesn't like keyboard shortcuts it seems. :)
Joannah Cramer
Registered User
Join date: 12 Apr 2006
Posts: 1,539
08-31-2006 06:57
From: Tere Karuna
I know can make "push buttons" to go into a HUD. Can animations be triggered by these buttons; and if so how fast will the AV react to the event?

Im assuming that a delay can be scripted into the buttons kinda like a "refresh timer" before they can be activated again?

Yes; you can see such things (along with free demo stands) in Abranimations store, for example... their dance HUDs (and other animation HUDs i think) operate on this very principle, though i dunno about the cooldown timers, but these can be implemented easily as well.
Suzari Wildung
Registered User
Join date: 28 Jun 2006
Posts: 5
It works this way
08-31-2006 12:36
I made such a hud, by simply having each button send a linked message to the root prim, and the root prim requesting permission and playing the animation. However, you will need to divide the animation names over the buttons, or have them preset
Tere Karuna
Registered User
Join date: 4 Jul 2004
Posts: 159
08-31-2006 16:12
Thanx guys :) Now that know its all possible Ill go thru my notecards and see which scripters dont have me muted yet...
_____________________
"ooohhhh we didnt know what we had till it was gone;
they paved secondlife and put up a shoping mall,
oooooo, ba ba ba....."
Ziggy Puff
Registered User
Join date: 15 Jul 2005
Posts: 1,143
08-31-2006 17:15
From: someone
Is it a problem to instead of "pushing" the button, one key can be hit (like F1) to activate the button?


I don't think you can do this part directly. You can set up a gesture and bind it to a key. In that gesture, you can say things, including on non-zero channels. So you can have a gesture that says (for example) "/12345 start dance" or something like that. Then your script needs to listen for this command, and act on it.

So, if you want the input to be a HUD button as well as a keyboard shortcut/gesture, you'll have to handle touch events, and also set up listeners.