Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

[Request] Help with Holodeck Related Rezzer

Bjorn Collins
Will draw for food..
Join date: 2 Sep 2007
Posts: 18
12-10-2008 00:46
First of all, goodmorning, goodday or just hello to everyone.

I have been searching the scripting tips and scriptlibrary for a few hours now, to find something similar to edit, but I have failed and therefore I now ask for help or suggestions here.

I do not look for a holodeck, but its the most precise relation there is.

What I am looking for, is something as simple as a rezzer - however with a few tweaks.

If you think of having a wall in a meeting room, where you have 3 buttons - one for a television, one for a graphics viewer and one for a combined viewer.

When you click button 1, a television is rezzed, now - when yo click button 2 the television is derezzed and the graphics viewer is rezzed, and when you click button 3 the graphics viewer is derezzed and both are rezzed.

I assume this will require 4 prims, + the actual objects within a rootprim - I will visually draw the view I have upon a solution here:

A rootprim, which holds the script for the rezzer aswell as the 2 objects needed (which are named "tv" and "gfx";). Then you have 3 buttons which are linked to the rootprim - fist is called "1", next is "2" and the last is "3".

I suppose there is need to make a script that first of all has a relation to the buttons needed (as mentioned above), second a llRezObject and then a llDie, also a grouprelated ownership - what I mean is, all users in the group its set to (not deeded to) will be able to use it.

What I dont want, is a blue drop down menu.
Yingzi Xue
Registered User
Join date: 11 Jun 2008
Posts: 144
12-10-2008 03:20
That wouldn't be hard to do. Also, you could do it with one prim if all you're using is a flat prim for your screen. TV (parcel media) is played on a particular texture. All you would have to do is make the prim's face that texture and specify a command or two to bring up the parcel media. As for a graphics viewer, I'm assuming it's just a texture viewer of sorts, also simple. You could also sandwich the prims together and use alpha to bring whichever screen you need to the forefront. Set the unused screens to alpha 0.0 and the one you want to use to alpha 1.0 (no transparency). The buttons would be simple to make as well.
Bjorn Collins
Will draw for food..
Join date: 2 Sep 2007
Posts: 18
12-10-2008 23:09
Both the TV and the Graphics viewer is complex objects consisting of several prims, otherwise your answer was not what I was looking. Thanks anyways.

Its a rezzing system, that will rez and de-rez (as said above).
Innula Zenovka
Registered User
Join date: 20 Jun 2007
Posts: 1,825
12-11-2008 04:53
If I've properly understood what you want to do, it's not difficult. Seems to me that you want to have the rezzed objects, the TV and the Graphics viewer, listening on the same channel. You put the TV in the inventory of Button A and the Graphics Viewer in the inventory of Button B.

When you press the appropriate button, it says, "boo" on the appropriate channel, and anything that's rezzed hears that and dies. A fraction of a second later it executes something like
CODE

llRezAtRoot(llGetInventoryName(INVENTORY_OBJECT, 0), llGetPos()+<1,0,0>, ZERO_VECTOR, ZERO_ROTATION, 0);
and rezzes the object it contains.

For rezzing both objects simultaneously, you want to use link messages. Put in each button,
CODE
   link_message(integer sender_num, integer num, string str, key id)
{
if (num !=99)
return // the message is not for me
llRezAtRoot(llGetInventoryName(INVENTORY_OBJECT, 0), llGetPos()+<1,0,0>, ZERO_VECTOR, ZERO_ROTATION, 0);
)


Your third button, which you press to rez both, contains something like
CODE
touch_start(integer total_number)
{
llSay(mychannel, "boo"); // clear anything that's already rezzed
llMessageLinked(LINK_ALL_OTHERS, 99, "", NULL_KEY); //tell both rezzers to do their stuff
}


I found the discussion and examples at /54/c4/241864/1.html very helpful for understanding this, particularly how to position my rezzed objects