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
  #4  
Old 12-06-2010, 08:50 PM
salesman salesman is offline
Finger lickin' good.
salesman's Avatar
Join Date: Nov 2008
Location: Colorado
Posts: 1,865
salesman has much to be proud ofsalesman has much to be proud ofsalesman has much to be proud ofsalesman has much to be proud ofsalesman has much to be proud ofsalesman has much to be proud ofsalesman has much to be proud of
I don't think mouse events or mouse location are synced serverside (I could be wrong).

Depending on what type of npc it is, you can just catch the mouse event on the clientside and then send a triggeraction to the server.

for level npcs, use triggerAction(x, y, ...)
for dbnpcs, or npcs placed with putnpc(), use triggerServer("npc", this.name, ...);

edit: If you just want the NPC to change its image, use setImg(), but if you want to place an image at the mouse's location, you need to send the mousex and mousey to the serverside.
__________________
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 04:59 AM.


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