Saturday, September 6, 2008

Object Chat Trick! [Level IV]

Object Chat Trick! [Level IV]

Chey discovered a neat little trick when objects chat: they respond to /me pretty much the same way avatars do.

You know the /me trick.

type in Chat /me says hi

And others see "Cheyenne Palisades says hi" instead of "Cheyenne Palisades: says hi"

If you make an object say something, /me will make it say its name in the same way-- and if you make the object's name a blank, it will say only what follows /me.

So, you can have an object say something like "Do not enter!" without its name apeparing.

Try it! Make an object, make a script, and add /me after the opening quotes in the lines with llSay. 

Cool, huh?

-----

default
{
  state_entry()
  {
  llSay(0, "/me Hello, Avatar!");
  }

  touch_start(integer total_number)
  {
  llSay(0, "/me Touched.");
  }
}


2 comments:

Baron K. Wulfenbach said...

Fraulein Palisades,

This could be quite useful. Danke.

Yrs.,

Klaus Wulfenbach

Tycho Beresford said...

The band I work for has a tip jar that says something like "Hippo Tip Jar thanks Tracy Stardust for her donation of L$150!" I made an invisible prim, stuck it on my back and scripted it so that every time I click it the chat says "Hippo Tip Jar thanks Tracy Stardust for her donation of L$1,500,000!" The name and amount are hard-coded, but I can change them on the fly. Quite fun to see the reactions of people.