View Single Post
  #1  
Old 02-24-2006, 06:18 AM
Prozac Prozac is offline
one of the good guys
Prozac's Avatar
Join Date: Jan 2006
Posts: 245
Prozac is on a distinguished road
Send a message via AIM to Prozac
calling public functions

So, in a weapon npc, i have this serverside:

PHP Code:
public function itemDesc()
{
 
this.msg="This is an item description";
 return 
this.msg;

then the player has the weapon, and I want a gui text window object called item_desc_text (necesarrily clientside) to get the text from the public function call, but all it returns is 0:

PHP Code:
item_desc_text.text=weapon-name.itemDesc(); 
so, what is the propper procedure to call a public function in a weapon, and have it return information to you/perform actions through another weapon (clientside or serverside etc)?
Reply With Quote