PDA

View Full Version : say2 functionality


jake13jake
01-08-2006, 01:01 PM
How would you do
#u, #d, #l, #r, or #i() for say2() in gs2 is what I'm wondering.

ApothiX
01-09-2006, 06:00 AM
How would you do
#u, #d, #l, #r, or #i() for say2() in gs2 is what I'm wondering.
I don't think any of those change whether you're doing it in gscript1 or gscript2. I could be wrong though :x

jake13jake
01-09-2006, 06:44 AM
Well, they're not in the wiki at all, and I had trouble getting #i to work. Also, is there any way to to turn off a say2?

Rick
01-09-2006, 09:27 AM
say2("#u #d #l #r #i(image.png)") should work fine.

jake13jake
01-10-2006, 02:49 AM
say2("#u #d #l #r #i(image.png)") should work fine.
well in that case, should I do
say2("#i(" @ npcs[i].image @ ") Item:" SPC npcs[i].itemname NL "Price:" SPC npcs[i].price);
Because that looks a bit uglyish/hacking

Yen
01-10-2006, 03:14 AM
well in that case, should I do
say2("#i(" @ npcs[i].image @ ") Item:" SPC npcs[i].itemname NL "Price:" SPC npcs[i].price);
Because that looks a bit uglyish/hacking


... Are you afraid of people hacking a say2?
Just think of the power they could gain over the server!

napo_p2p
01-10-2006, 03:54 AM
... Are you afraid of people hacking a say2?
Just think of the power they could gain over the server!

I think he means to say that the say2 code he posted looks like it has been "shaped as if by crude or ruthless strokes" (AKA hacked).

jake13jake
01-10-2006, 06:46 AM
I think he means to say that the say2 code he posted looks like it has been "shaped as if by crude or ruthless strokes" (AKA hacked).
Yea, and some of us are still trying to figure out why Stefan made signs serverside. I heard something about their being able to display certain variables. Still, makes it so say doesn't work clientside which creates a lot of work for me when converting old levels.

Admins
01-20-2006, 04:46 PM
The #i message code is for signs only, there are two versions:
#i(filename) - displays an image
#i(filename,x,y,width,height) - displays part of an image (like setimgpart)

On clientside you can use say2, but it is recommended to use say and say2 on serverside only. It means less data that needs to be sent to the client, you can use all serverside variables, you can use the translation system (currently on Kingdoms, but sometime soon also on Era), and the 'lag' between touching the npc and receiving the sign text is really low, especially in new scripting engine.
I don't see any problem with the say command, just use it on serverside.