View Single Post
  #10  
Old 11-03-2001, 03:51 AM
Loriel Loriel is offline
Somewhat rusty
Loriel's Avatar
Join Date: Mar 2001
Posts: 5,059
Loriel is a name known to allLoriel is a name known to allLoriel is a name known to allLoriel is a name known to all
Re: if (action)...clientside???

Quote:
Originally posted by Bravo_LAT-Admin
I have a simple question (might lead to the root of why my script won't work.) is if (action) commands only clientside? cause here is a test i did...and it worked clientside only.

if (actionberry)
{message ouch;}
//#CLIENTSIDE
if (actionberry)
{
if (playerdir==0) { putleaps 0,playerx+0.5,playery-1; };
if (playerdir==1) { putleaps 0,playerx-2,playery+1; };
if (playerdir==2) { putleaps 0,playerx+0.5,playery+2.5; };
if (playerdir==3) { putleaps 0,playerx+3,playery+1; };
}
Triggeraction works in every direction... clientside -> clientside, clientside -> serverside, serverside -> serverside and serverside -> clientside!
To fix your script, you need to use setshape or showcharacter to make the NPC server know the size of the NPC, so it can check if the trigger hit your NPC.
But an easier way would definately be making it all clientside: The triggering is sent to every player anyways, so it shows only locally, but locally for all players (only the NPC Server would not see the message then, but I doubt he cares).