![]() |
Textshadow serverside?
Hello, I've made a simple function which creates some text in the format I'm using:
PHP Code:
I'm supplying it with ids less than 200 so the text appears to all players. The text appears fine, however the shadow only appears on the client who created the text. Everyone else can see the text but not the shadow. Is textshadow supported serverside? Thanks. |
Quote:
However, what is it that you're trying to show? Would it be anything directly connected to the player? If yes, use an attribute with a gani attached. |
I have to use a gani to attach text to a player for all to see?
It's easier for me just to create another text image and place it offset from the first :P |
Quote:
|
Quote:
I believe this is done to prevent lag or something. I really don't know. edit: also before you point out that your shadowoffset is 2,2... it's because shadow offset goes by pixel. so it's more like +.2,+.2 which again, won't display serverside :) |
The best way to display such things is using attr[] - you can put scripts and variables in there.
The serverside sendtext() has just been added recently, the findimg() function is working but the variable that is returned currently doesn't have any attributes. Recent attributes like textshadow is not working for showimgs/findimgs below index 200 anyway - you should use attr[] instead because it is simple to use and gives unlimited possiblities. |
I can't find any examples of attr[] usage.
Should I just use player.attr[1] = findimg(id) ? It doesn't seem to work. I'm using indexes over 200 and nobody can see text from anyone else. |
Quote:
|
Quote:
They are listed in the player. vars (player.headimg, player.bodyimg) |
Quote:
|
Quote:
HTML Code:
DEFAULTHEAD head19.png |
I tried putting it in attr[9]
Still only the person who's clientside script created the image can see it. Should I use IDs below 200? |
Quote:
|
I've tried with indexes less than 200, the text shows but the shadow doesn't.
|
Like I said the new attributes like textshadow are not sent. You need to use attr[] and gani scripts, like
PHP Code:
PHP Code:
|
ah, i see.
Thanks :) |
Wait so I'm a little confused attr[] can be used outside of gani's?
so for example: PHP Code:
|
Quote:
|
is there any way to call a function from a gani?
I tried: player.attr[2] = "my.gani"; player.attr[2].te****nction(); te****nction is declared as public in the gani. Is there any way to do this? Also, doing as Stefan suggests and using with (findimg(200)) { (i had to change it to findweapon("name").findimg(200) for it to work)... I have many people with this text attached to them, every time the action is triggered it updates them all, even though I only want it to update the text for the player that triggered it and not everyone elses. |
Quote:
|
you can even use triggerserver(); in gani scripts, so I think functions should work to?
|
Quote:
|
Quote:
I just said it because it works :] |
| All times are GMT +2. The time now is 12:24 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.