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 12-06-2010, 03:57 AM
ZeroG ZeroG is offline
Developer
Join Date: Oct 2010
Posts: 12
ZeroG is on a distinguished road
Showimg serverside or serverside to clientside

PHP Code:
function onActionLeftMouse(){
   
showimg(196"green_rupee.png"mouse.x-0.5mouse.y-0.5);

I'm trying to get the image to appear serverside for everyone if a player clicks it. I'm not sure if showimg is clientside only or what.

If you can't use showimg serverside, then is is possible to use triggerserver/triggeraction to go from serverside to clientside? Similar to:

PHP Code:
function onCreated(){
  
this.attr[2] = this.name;
}
function 
onActionServerSide(){
  
this.destroy();
}
//#CLIENTSIDE
function onPlayerTouchsMe(){
  
triggerserver("npc"this.attr[2], NULL);

But instead of clientside to serverside, it's serverside to clientside.
If this is possible, I could loop through all the players and have the image be displayed to everyone on clientside.

Both scripts are on an npc, not a weapon.
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 01:19 PM.


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