Graal Forums  

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

 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 05-16-2014, 04:45 PM
i8bit i8bit is offline
Registered User
Join Date: Jul 2013
Posts: 146
i8bit is an unknown quantity at this point
Triggering action in other player

I am trying to stay away from Serverside functions.

How would I trigger an action in a Weapon on a player in front of me..

For example:
Player swinging sword
PHP Code:
//#CLIENTSIDE
function onKeyPressed(codekey){
 if (
key == "s"){
  
setAni("sword"NULL);
  
//trigger action "onHit" in the weapon "DamageSystem" to the player right in front
 
}

PHP Code:
//Damage system
//#CLIENTSIDE
function onHit(){
 
//what ever actions I want to take place

Reply With Quote
 


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 02:57 PM.


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