Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 09-14-2010, 01:39 AM
Deathborn123 Deathborn123 is offline
Owner of Dev Deathborn123
Deathborn123's Avatar
Join Date: Aug 2008
Location: Germany
Posts: 21
Deathborn123 is on a distinguished road
Npc |Server - Clientside| Communication

Hey guys!

I'm just making a baddysystem. So I'm wondering how you communicate between Clientside and Serverside in an npc class. To make a bit more understandable:

Baddy Class ( if the baddy gets hit)
PHP Code:
function onActionhurt()
{
if (
this.npchp params[0])
{
this.npchp -= params[0];
this.chat this.npchp;
}
else
{
this.npchp this.npchpmax;
this.chat this.npchp;
"-xpcalculator".Actionxp(this.npclevel);
}

Aight, so basicly what im doin is, whenever the baddy dies, it calls the public function "Actionxp" of the weapon "-xpcalculator". So everything works fine, if the baddy class is //#CLIENTSIDE. The problem is i dont want my baddies clientside, so my aim is to remove the //#CLIENTSIDE but if i do it he cant find the public function "Actionxp" anymore. Hope you got me and hope you got any resolutions for that

So far...
__________________
You cannot Prevent and Prepare for War at the same Time.
Reply With Quote
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 12:49 PM.


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