I have this on a NPC that is created.
PHP Code:
function onCreated() {
showcharacter();
setcharani("hiteffect", "");
this.attr[20] = "hiteffect.png";
this.dir = 2;
setTimer(0.25);
}
function onTimeOut()
{
destroy();
}
//#CLIENTSIDE
function onCreated() {
showText(200, this.x, this.y, "showg", "b", "" @(player.clientr.hitpoints));
with (findImg(200)) {
font = "showg";
style = "b";
layer = 23;
zoom = 2;}
sleep(2);
showText(100, 0, 0, "showg", "b", "");
}
It works, but I guess in clientside it doesn't know where it's own x and y value is... :/