![]() |
Triggeraction
Does anybody here know how to get triggeraction to work serverside? Cause for me it only works clientside. I have tried every serverside/clientside combination there is, and only sending clientside and recieving clientside works. Is there some special tag to go with it, like putting server in front of the action to send an action to the control NPC, to get it to work serverside?
|
You have to put server before the action name on server-side scripts and then read the action with if (actionserveractioname)
|
Quote:
|
It should work the same, but you need to make sure
the npc actually has some size (like use setshape 1,48,48 or setshape2) because otherwise the npcserver thinks its a hidden npc and doesn't get the action since 'triggeraction' triggers actions on a special point |
Does Setshape need to be clientside or serverside? Cause it seems to only work clientside, so I had put it clientside. Let me try putting it serverside and testing the triggeraction...
|
Yay! It worked. I also found out that you need to put setshape in both clientside and serverside. Clientside if you wanna change how the NPC blocks the player, and serverside for triggeraction and washit stuff. Stefan, you should add wasshot and waspelt to the serverside actions!
|
Stefan, could you also make it so you don't have to do showcharacter; to be able to use the washit function? Because washit only works if you call showcharacter; in the code.
*Edit* On second thought, I can't seem to get washit to work anymore... =/ I called setshape 1,48,48; both serverside and clientside, and I called showcharacter; both serverside and clientside, AND I put: if (washit) message Hit; on the serverside portion of it. Still no luck. =/ NPC Server hates me... *Edit* |
could u mix setshape and setshape2 together?
liek i just made this up........... NPC Code: |
Yes, on server-side use setshape, on
client-side use setshape or setshape2. That washit thing should work on both client- and server-side. One thing that is important is to give the npc power, like hearts = 3; otherwise the server/client thinks its a dead npc |
Quote:
|
THis has nothing to do with your post boco but i contributed alot to your foundation but you never did add my contributions to it!!!! (BOCO=MAKES GOBOOM CRY) :grrr:
|
Quote:
|
| All times are GMT +2. The time now is 02:15 PM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.