Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   Gani on Clientside (https://forums.graalonline.com/forums/showthread.php?t=65249)

Bl0nkt 04-08-2006 02:07 AM

Gani on Clientside
 
When a gani is shown clientside, it is supposed to show for everyone. Now, this may only apply to setAni(); as it changes the player's animation for everyone to see.

NPC Code:
//#CLIENTSIDE
function onCreated()
{
this.gang_name = "gang";
}

function onPlayerEnters()
{
setCharAni("era_gang_door_neutral", "");

setshape2 5, 3, {0, 0, 0, 0, 0,
22, 0, 0, 0, 22,
22, 0, 0, 0, 22};

drawoverplayer();
setTimer(0.05);
}

function onTimeout()
{
if (player.y in |y, y+2| && player.x in |x, x+3|)
{
if (player.guild == this.gang_name)
{
setCharAni("era_gang_door_allow", "");
}else
setCharAni("era_gang_door_intruder", "");
}
setTimer(.05);
}



Here is my script. It detects if the player is under it, and if their tag is this.gang_name, it shows one gani. Otherwise, it shows another. This part is working fine, except it only shows it for the player under it. Is there a way to show a gani for everyone on the clientside?

ZeLpH_MyStiK 04-08-2006 03:37 AM

do it serverside or use a showani?

Bl0nkt 04-08-2006 04:18 AM

Doing it serverside made it choppy and the animations would not set back.

ApothiX 04-11-2006 02:20 PM

Quote:

Originally Posted by Bl0nkt
Doing it serverside made it choppy and the animations would not set back.

Doing it clientside would be insecure for doors that are supposed to keep people out.

xAndrewx 04-11-2006 05:51 PM

1 Attachment(s)
Quote:

Originally Posted by ApothiX
Doing it clientside would be insecure for doors that are supposed to keep people out.

1 = door
2 = his seperate script

Bl0nkt 04-12-2006 01:24 AM

I've got it working now. Plus some extra features.


All times are GMT +2. The time now is 04:05 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.