Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

llSay, llInstantMessage, llOwnerSay, and why I hate you.

Zoey Helgerud
Overqualified
Join date: 13 Jun 2007
Posts: 44
01-27-2009 07:51
I've just about always noted how chatty inanimate objects in SL seem to be, what with the beer attachments that tell you to "watch that third sip" (the stupidity of which is another rant entirely), greeters that spam huge blocks of text when ever someone gets in range, to guns, huds, and various other attachments that thank everyone in the area for their purchase of so-and-so's emporium of poorly scripted crap, and frankly, I'm sick of it.

It's bad enough that so many objects and attachments simply spit out text describing something happening, because people are too lazy to find/make appropriate animations and sound effects for it to actually DO what they're describing. I barely even count attachments/gestures that try to cobble together animations and sounds from the library and freebies that have been floating around since the dawn of time as having made the effort. SL isn't an old-fashioned text PUD, damnit.

But all the lengthy, unnecessary text messages that get sent to people who don't care annoys me even further. All it takes is just a couple seconds to consider who really needs to hear the message you're sending (maybe a few more to consider who actually cares) to decide the appropriate way to send it. Instructions, and anything else activated by attaching or sitting on an object should be sent ONLY to the person who triggered them. The same goes for greeters (especially if you're not keeping track of who has already been greeted recently) if you're going to spit out a huge block of text to every new arrival, DON'T USE LLSAY. If the greeting is also supposed to serve as a notice that someone has arrived, it is entirely possible to add another line ie: llSay(0, llDetectedName(0)+" has arrived";). It won't even hurt you.


AND NO, USING LLWHISPER ISN'T GOOD ENOUGH

For those of you who may be unaware of the alternatives to llSay, llWhisper, and llShout, here's a quick overview:

llInstantMessage(key id, string message)
This function allows you to send a message to a single avatar, wherever they are. Messages from llInstantMessage appears just like messages from an object using llSay, but are only received by the specified user.

llOwnerSay(string message)
This function sends a message only to the owner of the object. Perfect for weapons, HUDs and other attachments. Unlike llInstantMessage, llOwnerSay can not send messages from a different region.
Rolig Loon
Not as dumb as I look
Join date: 22 Mar 2007
Posts: 2,482
01-27-2009 08:07
Good morning to you too. Have a pleasant day.;)
Cheree Bury
ChereeMotion Owner
Join date: 6 Jun 2007
Posts: 666
01-27-2009 08:36
For the most part, I agree with you on this one. That is why you will hear very few talking objects in my store. You get no greeting, no landmarks, nothing when you arrive.

The only thing that talks are my pose vendors. When you first get on to try the poses, they say "You may touch the back of the vendor to go to the next pose". I use llWhisper for 2 reasons: I want the person to know it, and I do not want the 2 second delay that is associated with llInstantMessage. I could go to the trouble of adding another script that sent the message and eliminate the delay, but that seems overly complex for the task. And yes, people do click it within 2 seconds of getting the message.

I like for my shop to be quiet, and I hope my customers appreciate it.


There have been times when my neighbors have had talking objects that my customers could hear. I beat them back with a stick (OK, I asked them nicely and they adjusted them, but I had a stick ready.)
_____________________
Visit ChereeMotion - Life's Best Pinup Poses
http://slurl.com/secondlife/Wild%20Rice/38/230/51
Argent Stonecutter
Emergency Mustelid
Join date: 20 Sep 2005
Posts: 20,263
01-27-2009 08:41
llInstantMessage isn't a solid solution to spam either.

I've had up to a dozen "Copybot Protector v$RANDOMNUMBER low spam: !quit" go off when I show up in an area. "Low spam" my sainted aunt Reba!
_____________________
Argent Stonecutter - http://globalcausalityviolation.blogspot.com/

"And now I'm going to show you something really cool."

Skyhook Station - http://xrl.us/skyhook23
Coonspiracy Store - http://xrl.us/coonstore
Zoey Helgerud
Overqualified
Join date: 13 Jun 2007
Posts: 44
01-27-2009 08:55
From: Argent Stonecutter
llInstantMessage isn't a solid solution to spam either.

I've had up to a dozen "Copybot Protector v$RANDOMNUMBER low spam: !quit" go off when I show up in an area. "Low spam" my sainted aunt Reba!


That's because the person who scripted those is a moron.

Using llInstantMessage helps by limiting who hears the message to the people who need it, but it can't stop the scripter from deciding that everyone needs that message every 30 seconds.

Also, the 2 second delay can be worked around, by setting up a second script that sends the instant message, relayed by llMessageLinked, but I'll forgive most vendor scripts, since that isn't a foolproof workaround.
Argent Stonecutter
Emergency Mustelid
Join date: 20 Sep 2005
Posts: 20,263
01-27-2009 09:07
From: Zoey Helgerud
That's because the person who scripted those is a moron.
No, I don't think so. A con-artist, and an a-hole, yes, but not a moron. After all, look how many people have bought the stupid useless spammy things.
_____________________
Argent Stonecutter - http://globalcausalityviolation.blogspot.com/

"And now I'm going to show you something really cool."

Skyhook Station - http://xrl.us/skyhook23
Coonspiracy Store - http://xrl.us/coonstore
Winter Ventura
Eclectic Randomness
Join date: 18 Jul 2006
Posts: 2,579
01-27-2009 12:08
Many people dismiss llInstantMessage as "Laggy" because of the short throttle-delay that comes with it. But many times, this isn't even an issue. But if it is slowing down your script, you can pass that function to another script.

instantMessage.lsl
CODE

default
{
link_message (integer sender, integer num, string message, key id)
{
if (llToLower(llGetSubString(message, 0, 2)) == "im|")
{
llInstantMessage(id, llDeleteSubString(message, 0, 2));
}
}
}


Then to trigger the IM, slip this function into your other scripts.

CODE

InstantMessage(key id, string message)
{
llMessageLinked(LINK_SET, 0, "IM|" + message, id);
}


Then use it like llInstantMessage, just without the "ll".

CODE

InstantMessage(llGetOwner(), "hi");


You know.. llSetText is under-rated.

As annoying as it is to have hovertext on a vendor, showing through the walls.. hovertext is exceptionally useful for short, transient notices, and for information displays in HUDs.

In fact, a similar script can be made to pop-up hovertext, and then start a short little timer, and delete the text when the timer runs out.

CODE

default
{
link_message (integer sender, integer num, string message, key id)
{
if (llToLower(llGetSubString(message, 0, 2)) == "im|")
{
llSetText(llDeleteSubString(message, 0, 2), <1,0.75,0>, 1.0);
llSetTimerEvent(2);
}
}

timer()
{
llSetTimerEvent(0);
llSetText("", <0,0,0>, 0.0);
}
}
_____________________

● Inworld Store: http://slurl.eclectic-randomness.com
● Website: http://www.eclectic-randomness.com
● Twitter: @WinterVentura
Innula Zenovka
Registered User
Join date: 20 Jun 2007
Posts: 1,825
01-27-2009 13:40
Me, I just wish more people would use llOwnerSay and llInstantMessage when they design talkative attachments.

While the opinions of so-and-so's genitalia (or, even worse, her unborn virtual child -- bleh) may well be matter of great interest to her and her immediate friends, that is not necessarily the case for everyone in the club or shop.
Bloodsong Termagant
Manic Artist
Join date: 22 Jan 2007
Posts: 615
01-27-2009 15:10
short delay?

its TWO WHOLE SECONDS!!!

;P


but, seriously. i had an object with a setup menu that would acknowledge setting changes taking effect in ownersay. but people wanted it group-owned, so i changed it to instant message.

flipping through the settings used to be quick, and the menu always reappeared so you could do another setting. now, however, you make a selection, the object acknowledges........
and it looks like the menu isnt going to come back, so you click it again and start a NEW menu session, then get the delayed menu then... ARGH. even i did that, and i KNOW why theres a menu delay.
Dora Gustafson
Registered User
Join date: 13 Mar 2007
Posts: 779
Spam relay
01-27-2009 15:46
From: Zoey Helgerud

It's bad enough that so many objects and attachments simply spit out text describing something happening, because people are too lazy to find/make appropriate animations and sound effects for it to actually DO what they're describing. I barely even count attachments/gestures that try to cobble together animations and sounds from the library and freebies that have been floating around since the dawn of time as having made the effort. SL isn't an old-fashioned text PUD, damnit.

Here is a small script that might help if you are cornered:
CODE

// Simple 'Spam relay' Created by Dora Gustafson, 2008, Studio Dora
// The script will listen on the public channel and whatever comes out of an object
// will be send by IM to the object's owner
// Will relay to all owners of objects heard on the public channel
// Only objects, not chatting avatars are affected
// WARNING: Ask the spammer kindly to stop spamming you before using this script
// WARNING: Don't use on other peoples land, you may easily abuse the land owner!

default
{
state_entry()
{
llListen( PUBLIC_CHANNEL, "", NULL_KEY, "");
}

listen(integer cannel, string name, key id, string message)
{
key ok = llGetOwnerKey( id );
if ( ok != id ) llInstantMessage( ok, message );
}
}

You may add your own personal message to the IM:)
And PLEASE observe the warnings!
Good luck
_____________________
From Studio Dora
Argent Stonecutter
Emergency Mustelid
Join date: 20 Sep 2005
Posts: 20,263
01-27-2009 15:52
Too bad you can't find the poor folks who were tricked into wasting money on a "Copybot Defender" that way.
_____________________
Argent Stonecutter - http://globalcausalityviolation.blogspot.com/

"And now I'm going to show you something really cool."

Skyhook Station - http://xrl.us/skyhook23
Coonspiracy Store - http://xrl.us/coonstore
Hewee Zetkin
Registered User
Join date: 20 Jul 2006
Posts: 2,702
01-27-2009 21:45
Ah, I remember back when llOwnerSay() was first introduced. I was SOOOOOO happy! Care to start a JIRA to petition LL to change the default 'New Script' to use llOwnerSay() instead of llSay()? I'll vote. :cool:
Argent Stonecutter
Emergency Mustelid
Join date: 20 Sep 2005
Posts: 20,263
01-28-2009 05:59
Oh, that's a *sweet* idea. Or else use llInstantMessage(llDetectedKey(0)). Or even... dare I suggest it... promote good coding practice and show people a little conditional love:

touch_start(integer num_detected)
{
key id = llDetectedKey(0);
if(id == llGetOwner()) llOwnerSay("Hello Boss!";);
else llInstantMessage(id, "Hello, Avatar!";);
}
_____________________
Argent Stonecutter - http://globalcausalityviolation.blogspot.com/

"And now I'm going to show you something really cool."

Skyhook Station - http://xrl.us/skyhook23
Coonspiracy Store - http://xrl.us/coonstore
Zoey Helgerud
Overqualified
Join date: 13 Jun 2007
Posts: 44
02-01-2009 19:15
From: Bloodsong Termagant
short delay?

its TWO WHOLE SECONDS!!!

;P


but, seriously. i had an object with a setup menu that would acknowledge setting changes taking effect in ownersay. but people wanted it group-owned, so i changed it to instant message.

flipping through the settings used to be quick, and the menu always reappeared so you could do another setting. now, however, you make a selection, the object acknowledges........
and it looks like the menu isnt going to come back, so you click it again and start a NEW menu session, then get the delayed menu then... ARGH. even i did that, and i KNOW why theres a menu delay.

Well if you're making a vendor, using llInstantMessage and sleeping the script for 2 seconds can result in someone paying you money without getting their item.

I'm not against ANY objects using open chat, just against them using it without having a good reason to
Lazink Maeterlinck
Registered User
Join date: 8 Nov 2005
Posts: 332
02-01-2009 20:02
2 seconds is a long time, especially if you're trying to IM multiple people. Work around works for most things, but then you run into system resources (even idle scripts take some processes), so what are you left with? llWhisper, llSay.....

Also that handy mute object button. :)

Now annoying, are menu dialog boxes that don't give options, that are used just for greeting or giving information. Sure, it doesn't spam people around you, but fills up that nice right upper corner of my screen :P
Dylan Rickenbacker
Animator
Join date: 11 Oct 2006
Posts: 365
02-02-2009 07:31
@Dora:

Oh how I would have loved this idea back in the day when I was living on mainland and someone near was running a bunch of shouting lucky chairs! (Yeah, I muted them about half a dozen times a day, but for some reason they wouldn't stay muted.)
Damanios Thetan
looking in
Join date: 6 Mar 2004
Posts: 992
02-02-2009 08:16
Don't forget llDialog

It's more obtrusive (sometimes maybe even preferred), but it has a shorter delay than llInstantMessage and basically has the same advantages (no spam, can be used for all avies).

Remember, you don't have to actually 'do' anything with the results of a lldialog call.
_____________________
Ruthven Willenov
Darkness in your light
Join date: 16 Jan 2008
Posts: 965
02-02-2009 08:29
From: Damanios Thetan
Don't forget llDialog

It's more obtrusive (sometimes maybe even preferred), but it has a shorter delay than llInstantMessage and basically has the same advantages (no spam, can be used for all avies).

Remember, you don't have to actually 'do' anything with the results of a lldialog call.


:-p

From: Lazink Maeterlinck

Now annoying, are menu dialog boxes that don't give options, that are used just for greeting or giving information. Sure, it doesn't spam people around you, but fills up that nice right upper corner of my screen :P
Hewee Zetkin
Registered User
Join date: 20 Jul 2006
Posts: 2,702
02-02-2009 11:09
From: Zoey Helgerud
Well if you're making a vendor, using llInstantMessage and sleeping the script for 2 seconds can result in someone paying you money without getting their item.

This actually isn't extremely likely. It's not like you miss everything during those two seconds. Events continue to queue. They just don't get serviced until afterwards. Some events might miss the queue if it accumulates too much, but it's not too difficult to design your scripts so you don't miss important events like money (e.g. filter your listens well and don't put unnecessary event handlers where you receive money events).

See also http://www.lslwiki.net/lslwiki/wakka.php?wakka=llMinEventDelay (not that you'd use it for this case, but it has info about what happens during delays--which does include llSleep() and script delays imposed by functions like llSetPos() and llInstantMessage(); anything that pushes off the execution of the next event handler).
Zoey Helgerud
Overqualified
Join date: 13 Jun 2007
Posts: 44
03-03-2009 16:59
From: Damanios Thetan
Don't forget llDialog

It's more obtrusive (sometimes maybe even preferred), but it has a shorter delay than llInstantMessage and basically has the same advantages (no spam, can be used for all avies).

Remember, you don't have to actually 'do' anything with the results of a lldialog call.


That's a good idea in some situations, such as giving notice of certain sim rules to new arrivals, etc. Important things that you want to make sure people at least glance at.
Winter Ventura
Eclectic Randomness
Join date: 18 Jul 2006
Posts: 2,579
03-03-2009 18:55
From: Zoey Helgerud
That's a good idea in some situations, such as giving notice of certain sim rules to new arrivals, etc. Important things that you want to make sure people at least glance at.


Keep in mind though, that MANY people consider "blue popups" on arrival someplace, much the same as webpage popups. So, while llDialog does give you a nice chance to say something, be careful with it. Even one popup can get you AR'ed for spam if they're in a foul mood.
_____________________

● Inworld Store: http://slurl.eclectic-randomness.com
● Website: http://www.eclectic-randomness.com
● Twitter: @WinterVentura
SuezanneC Baskerville
Forums Rock!
Join date: 22 Dec 2003
Posts: 14,229
03-03-2009 20:34
You haven't touched on why you hate me.
_____________________
-

So long to these forums, the vBulletin forums that used to be at forums.secondlife.com. I will miss them.

I can be found on the web by searching for "SuezanneC Baskerville", or go to

http://www.google.com/profiles/suezanne

-

http://lindenlab.tribe.net/ created on 11/19/03.

Members: Ben, Catherine, Colin, Cory, Dan, Doug, Jim, Philip, Phoenix, Richard,
Robin, and Ryan

-
Johan Laurasia
Fully Rezzed
Join date: 31 Oct 2006
Posts: 1,394
03-03-2009 21:05
Well, ya know, this is a scripting forum, so take your rant over to resident answers where ranting seems go go around here. As far as stupid animations go, you're either triggering them yourself, or standing near someone who does, neither of which I do personally. So, what I'm saying is if you're tired of hearing stupid crap, don't put yourself in a situation where that stuff exists. I almost exclusively use llOwnerSay() and/or llInstantMessage() to communicate information from an object to a user so as to not clutter the open channel with information not intended for others. I don't really need someone who obviously has outgrown hanging out in clubs sipping virtual beer to tell me how to script.
_____________________
My tutes
http://www.youtube.com/johanlaurasia
Void Singer
Int vSelf = Sing(void);
Join date: 24 Sep 2005
Posts: 6,973
03-03-2009 23:53
sheesh rutting season has started already?

OP's point condensed:
note for new/amateur scriptors- please only communicate when and with whom you need to by script. it'll make you look more professional, and keep other people from wanting to write scripts that that spam messages and redirect them to you, en masse. (plus your customers won't be bitching to you about their customers bitching at them)

PS (that redirect script made me laugh)
_____________________
|
| . "Cat-Like Typing Detected"
| . This post may contain errors in logic, spelling, and
| . grammar known to the SL populace to cause confusion
|
| - Please Use PHP tags when posting scripts/code, Thanks.
| - Can't See PHP or URL Tags Correctly? Check Out This Link...
| -
Lily Cicerone
Registered User
Join date: 25 Jan 2007
Posts: 30
03-04-2009 13:48
Re: the 2 second llInstantMessage delay --

For some reason, people always seem to neglect the llMessageLinked function. Instead of having your main script send the instant message, redirect it to another script via

string text = your message here;
key target = the person whom you'd like to contact;
llMessageLinked ( LINK_THIS, 1, text, target );

then in a separate script within the same prim:

link_message ( integer sender, integer number, string message, key id )
{
if ( number == 1 )
{
llInstantMessage ( id, message );
}
}

Now the separate instant message script takes the delay instead of your main script, which is free to continue processing data. Problem solved.

And finally, yes, I agree about chat spam, but do we really need rants in the scripting tips forum? If the spam annoys customers, they'll avoid that store, and the owner will learn or lose sales. If you don't like it, don't visit there. I'm assuming most people who have been in Second Life for more than a year have long since stopped frequenting clubs anyway.
1 2