|
Niles Todd
Registered User
Join date: 20 Jul 2006
Posts: 17
|
11-05-2006 07:32
HI! I've just made a bath with water that at the touch of a button drains away and refills. the only problem I have is that I cant link the bath and the water and keep the effect. So when I move the bath, the water stays in the same place, but still moves when i press the said button.
I've used the scripts from a hot tub that i found in my inventory. I think it was called super hot tub 1.1? with steam and bubbles. Some of you might know it.
Is there a cure for this? is there anybody out there how know of a simple fix or can help me fix this?
maybe a script i can inc in the build?
Im more than happy to pay somebody to help me fix this problem.
|
|
Deanna Trollop
BZ Enterprises
Join date: 30 Jan 2006
Posts: 671
|
11-05-2006 08:32
In the tub object's moving_end event, Whisper/Say/Shout a message containing the tub's new position, and have the water move to that position (with appropriate offset) when it hears that message.
Alternately, put a copyable version of the water in the tub's inventory. In the tub's moving_start event, send a message to the existing water to kill itself, and rez new water after the tub stops moving.
|
|
Jesse Barnett
500,000 scoville units
Join date: 21 May 2006
Posts: 4,160
|
11-05-2006 09:43
IF the water is copyable and if when you say you drain or fill the water , that it is either there or isn't. You can put this script in the hot tub button. (it may be necessary to adjust the rotation also): vector offset = <0.0, 0.0, 0.0>;//Adjust as needed
default { touch_start(integer num_detected) { vector rez_pos = llGetPos() + offset; llRezObject("hot tub water", rez_pos, ZERO_VECTOR, llGetRot(), 42); state derez; } } state derez{ touch_start(integer num_detected) { llWhisper(-906, "derez"); state default; } }
and this script in the water: default { state_entry() { llListen( -906, "hot tub", NULL_KEY, "" ); } listen(integer channel, string name, key id, string message) { if (message == "derez") { llDie(); } } }
Note: THe hot tub and the water will either need to be renamed to the same as in the scripts or the scripts will need to be changed to the object names. After the scripts are in both then take the water back into inventory. Edit the hot tub and place the water inside it's contents.
_____________________
I (who is a she not a he) reserve the right to exercise selective comprehension of the OP's question at anytime. From: someone I am still around, just no longer here. See you across the aisle. Hope LL burns in hell for archiving this forum
|
|
Llauren Mandelbrot
Twenty-Four Weeks Old.
Join date: 26 Apr 2006
Posts: 665
|
11-05-2006 12:44
Alternatively, select both the tub and the water, like you would if you were going to link them, then move them both at once, as a unit. I`ve done this many times.
_____________________
- ninjafoo Ng Says:
November 4th, 2006 at 7:27 am We all love secondlife so much and were afraid that the magic will end, nothing this good can ever last…. can it?
|