View Single Post
  #5  
Old 07-30-2017, 11:19 AM
maximus_asinus maximus_asinus is offline
RIP DarkCloud_PK
Join Date: Oct 2001
Location: Canada
Posts: 3,746
maximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond repute
Quote:
Originally Posted by cbk1994 View Post
Post
I see how the class works, but I don't understand what is happening in your post so bear with me.
HTML Code:
function deposit(temp.amountToDeposit) { 
} 
I understand that "deposit" is a custom function. Is it being called by the triggerserver command? And how is "temp.amountToDeposit" assigned a value? I assume triggerserver is passing the value of the chat, similar to how tokenize worked in GS1, to the function?

Does including the variable name in the function act similarly to assigning the variable value? Like "temp.amountToDeposit = player.chat.substring(9).trim());" ?

HTML Code:
function onActionServerSide(temp.cmd, temp.amount) { 
  if (temp.cmd == "deposit") { 
    this.deposit(temp.amount); 
  } 
} 
Again, how does "temp.cmd" and "temp.amount" get assigned values? In the deposit function I can sort of understand that triggerserver calls the function. Does "onActionServerSide" also catch the values that are being sent? Maybe it would help if you posted the format of how triggerserver is to be used.

Quote:
Originally Posted by fowlplay4 View Post
Post
Thanks, these were things I didn't really consider. So mostly join is used for convenience?
__________________
Save Classic!

Last edited by maximus_asinus; 07-30-2017 at 12:20 PM..
Reply With Quote