Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting > New Scripting Engine (GS2)
FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #16  
Old 04-26-2006, 04:59 PM
ApothiX ApothiX is offline
Okiesmokie
Join Date: May 2004
Posts: 1,447
ApothiX is on a distinguished road
Quote:
Originally Posted by Raeiphon
On the subject of triggeractions, couldn't you locate a function above the //#CLIENTSIDE statement and when called, it would run serverside?
You cannot call serverside functions from the clientside. To do such a thing you would have to do like:

PHP Code:
function MyKewlFunction(mykewlparam) {
  echo(
"WEee: " mykewlparam);
}

function 
onActionServerside() {
  if(
params[0] == "mykewlfunction") {
    
MyKewlFunction(params[1]);
  }
}

//#CLIENTSIDE
function onWeaponFired() {
  
triggerserver("gui""MyKewlWeapon""mykewlfunction""OMG CALLED FROM CLIENTSIDE");

__________________


[06:24:19] * Parts: Skyld (i=silent@unaffiliated/skyld) ("Perhaps Okiesmokie did not realise that I like the boys. ")
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 07:04 PM.


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