llSay with no name in front
|
|
Archon Kipling
Registered User
Join date: 10 Oct 2005
Posts: 4
|
03-17-2006 15:57
I have just recently seen an item in the game that says things without prefixing the name of the object in front. I know lsl fairly well but have no idea how to do this.
example: The lovely smell of lavendar fills the air around Jane Smith.
I can only get a script to do: Object: The lovely smell of lavendar fills the air around Jane Smith.
What is it that makes this happen?
|
|
CrazeeTastee Gupte
Registered User
Join date: 13 Nov 2005
Posts: 13
|
03-17-2006 16:02
From: Archon Kipling I have just recently seen an item in the game that says things without prefixing the name of the object in front. I know lsl fairly well but have no idea how to do this.
example: The lovely smell of lavendar fills the air around Jane Smith.
I can only get a script to do: Object: The lovely smell of lavendar fills the air around Jane Smith.
What is it that makes this happen? Perhaps the object is using a /me. In chat, if you were to type "/me smiles at you.", people around you would see: Archon Kipling smiles at you. Objects can do this too. Maybe the object was "The" or something? That way, if it llSay()-ed "/me lovely smell of lavender fills the air around Jane Smith.", people would see: The lovley smell of lavender fills the air around Jane Smith. I could be wrong, but this seems like the easiest way to do it, especially if the name of the object doesn't really matter to you.
|
|
Ziggy Puff
Registered User
Join date: 15 Jul 2005
Posts: 1,143
|
03-17-2006 16:18
If everything it says starts with the word 'The', that would be a clue 
|
|
Nathan Stewart
Registered User
Join date: 2 Feb 2005
Posts: 1,039
|
03-17-2006 16:22
the only way i know to do this is to empty the object name field in edit, and also use the /me trick ie llSay(0, "/me the lovely smell of lavender fills the air around Jane Smith."  ;
|
|
Fractal Mandala
Registered User
Join date: 15 Dec 2003
Posts: 60
|
03-17-2006 16:25
If "/me" works for objects, you could rename the object to the first word in the string to be said. Hmm, this calls for testing.
|
|
nimrod Yaffle
Cavemen are people too...
Join date: 15 Nov 2004
Posts: 3,146
|
03-17-2006 16:37
If you backspace the name of a prim, the put in a space, It'll look like this: " : Test..." Er.. Upon further testing, /me does work too 
_____________________
"People can cry much easier than they can change." -James Baldwin
|
|
Hugsy Penguin
Sky Junkie
Join date: 20 Jun 2005
Posts: 851
|
03-17-2006 20:16
The SayMessage() function here seems to work well. SayMessage(string msg) { string name = llGetObjectName(); llSetObjectName(""); llSay(0, "/me " + msg); llSetObjectName(name); }
default { touch_start(integer total_number) { SayMessage("Hello World!"); } }
HP
|
|
Archanox Underthorn
Registered User
Join date: 20 May 2003
Posts: 168
|
03-18-2006 09:02
You're not really limited to a static name either since we have llSetObjectName(). It would be easy to grab the first word or words and set the objects name to that before sending the message.
_____________________
Archatek
Home to some of the highest quality katanas and other blades available in SL. Co-creator of the Samurai Island Combat System, one of the best melee combat systems available, come check it out!
___________________
|