|
|
|
// Jippen Faddoul's Poseball script - Low ram/lag posepall thats just drag-and drop simple
// Copyright (C) 2007 Jippen Faddoul
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License version 3, as
// published by the Free Software Foundation.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>
//This text will appear in the floating title above the ball
string TITLE="Sit here";
//You can play with these numbers to adjust how far the person sits from the ball. ( <X,Y,Z> )
vector offset=<0.0,0.0,0.5>;
///////////////////// LEAVE THIS ALONE \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
string ANIMATION;
integer visible = TRUE;
key avatar;
vector COLOR = <1.0,1.0,1.0>;
float ALPHA_ON = 1.0;
float ALPHA_OFF = 0.0;
show(){
visible = TRUE;
llSetText(TITLE, COLOR,ALPHA_ON);
llSetAlpha(ALPHA_ON, ALL_SIDES);
}
hide(){
visible = FALSE;
llSetText("", COLOR,ALPHA_ON);
llSetAlpha(ALPHA_OFF, ALL_SIDES);
}
default{
state_entry() {
llSitTarget(offset,ZERO_ROTATION);
if((ANIMATION = llGetInventoryName(INVENTORY_ANIMATION,0)) == ""){
llOwnerSay("Error: No animation");
ANIMATION = "sit";
}
llSetSitText(TITLE);
show();
}
touch_start(integer detected) {
//llOwnerSay("Memory: " + (string)llGetFreeMemory());
if(visible){ hide(); }
else { show(); }
}
changed(integer change) {
if(change & CHANGED_LINK) {
avatar = llAvatarOnSitTarget();
if(avatar != NULL_KEY){
//SOMEONE SAT DOWN
hide();
llRequestPermissions(avatar,PERMISSION_TRIGGER_ANIMATION);
return;
}else{
//SOMEONE STOOD UP
if (llGetPermissionsKey() != NULL_KEY){ llStopAnimation(ANIMATION); }
show();
return;
}
}
if(change & CHANGED_INVENTORY) { llResetScript(); }
if(change & CHANGED_OWNER) { llResetScript(); }
}
run_time_permissions(integer perm) {
if(perm & PERMISSION_TRIGGER_ANIMATION) {
llStopAnimation("sit");
llStartAnimation(ANIMATION);
hide();
}
}
}
Mah OpenLife Blahg:
http://socedge.wordpress.com/ |
|
|
|
 |  |
|
|
|
It occurred to me that we may have some pretty new people who have never made a poseball before that may come across this script so I made this quick new user guide to making a poseball and using the script above.
You can turn the visibility of the poseball on and off by “touching” (left clicking) it.
New user’s guide to how to use the poseball script:
1. Make a poseball. Rez a sphere and size it to about 0.250 all around (X, Y, Z) Color it if you like.

Set the rotation of the poseball to 0.00 (X,Y,Z)

2. Drop an animation in that you want to use.
3. Drop the script above into the poseball.
4. Right Click the poseball and choose edit.
5. Right Click again and choose “Sit”
6. Adjust to desired height/position.
7. Enjoy
Mah OpenLife Blahg:
http://socedge.wordpress.com/ |
|
|
|
 |  |
|
|
|
As a newbie to making poseballs in OL, this script was very helpful and simple to use.... :-))) |
|
|
|
 |  |
|
|
|
I am glad to hear you found it useful. :)
Welcome to OLG btw. Mah OpenLife Blahg:
http://socedge.wordpress.com/ |
|
|
|
 |  |
|
|
|
Hi Mac,
Thanks for the info! I was wondering, will the script support other animations? Like an "eat" or "drink"?
Thanks!
Nice to see you in OL. I've read some of your SL blogs in the past.
ttfn - Copper |
|
|
|
 |  |
|
|
|
Hi Copper,
This script should work for any animation. Therefore you could even utilize it to make a dance ball. What it won't do is sequence more than one animation.
Cheers. |
|
|
|
 |  |
|
|
|
Hi Copper! Good to see you here too. I hope you find OpenLife to be as great as I have.
Thanks, Leck for helping him out too. :) Mah OpenLife Blahg:
http://socedge.wordpress.com/ |
|
|
|
 |  |
|
 | Alura |
| 10 posts |
| Openlife Newbie |
|

|
|
|
Hi,
It works great as a poseball assist. I had a problem though, not sure what to do to fix it. Once I stood up, the pose ball went invisible. I can see it with "highlight transparent" but even when I reset it, it won't come back into "visible"...
Any ideas or is an OL issue?
Alura |
|
|
|
 |  |
|
|
|
Hi Alura. SImple fix and not an OLG issue. It is actually a feature of the script.
You can turn the visibility of the poseball on and off by “touching” (left clicking) it.
Happy posing. :D Mah OpenLife Blahg:
http://socedge.wordpress.com/ |
|
|
|
 |  |
|
 | Alura |
| 10 posts |
| Openlife Newbie |
|

|
|
|
Hi!
Well, that doesn't work yet...could be my/our region is slow to upload the scripts. Took about 4 hours for the fire scripts to work..lol Anyway...the poseball does "reappear" in a few minutes..so I stopped worrying about it. The script works great and I even set up a dance. YEAH!!!
The newest experience is getting tossed to the corner of our region when I try to edit the permissions..whoot!
Gotta love a new grid system..grins..
Alura |
|
|
|
 |  |
|
|
|
Alura wrote
Took about 4 hours for the fire scripts to work..lol
|
Just a little question; those four hours... is that the time it took to "save the script" or is that the time it took to use the new animation/pose?
I have used this script with a new animation, but it still shows the standard sit... so i'd like to know if it takes 4 hours before the new animation shows, or if i did something wrong :).
Kind regards,
Phil |
|
|
|
 |  |
|
 | Alura |
| 10 posts |
| Openlife Newbie |
|

|
|
|
Hi Phil,
In my experience, which is fairly new, it took a few hours OL time for the script to start to work. I cleared Cache/relogged etc. That didn't work, but when I popped back on a few hours later, it was working well. The pose balls work right away. It was the animation one that took time.
Hope that clarifies it.
Alura |
|
|
|
 |  |
|
|
|
Hi Alura,
thanks for your answer. Same case here :) I left them "not-working", came back somewhat later and they worked fine :)
Guess we'll need to have a little patience with the animations... though i wonder; if i now give furniture with those animations in to someone; does that person then also needs to wait that long before it works? If so, i better write that in the notecards :)
Regards,
Phil |
|
|
|