SphereCommunity
On=@Click problem - Printable Version

+- SphereCommunity (https://forum.spherecommunity.net)
+-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d)
+--- Forum: General Help (/Forum-General-Help)
+--- Thread: On=@Click problem (/Thread-On-Click-problem)



On=@Click problem - Gil Amarth - 05-15-2012 03:37 AM

Is this trigger working with the latest clients? (I use 7.0.23.1)

Because I use the next code:

[ITEMDEF i_sand]
ID = i_ore_iron
NAME = Sand
SKILLMAKE = MINING 5.0
VALUE = 1

ON=@Click
SERV.LOG Trigger activated
RETURN 1

But the trigger never fires, Is this and old trigger who only worked in the past, or what is it?


RE: On=@Click problem - Barnabus - 05-15-2012 06:17 AM

I do know Click became obsolete in the later clients, and i think it had something to do with the tooltip stuff.
If you were clicking to show a name or information in game id say use the tooltip.
To send a command like you have I would suggest using DClick it will work.


RE: On=@Click problem - Gil Amarth - 05-16-2012 03:03 AM

Yes, the problem with tooltips is the server sends the packet information to every client who enter near of this object. I have tried, and @ClientTooltip fires when you enter aproximately at 20 tiles of range. so it´s very resource expensive.

So if I want to put a message in hundreds of items, the server would be laggy because it must to send information to every near client.

With one Click I would put a message easy only when is clicked, and with DClick I would interfer with other scripts who uses DClick, like smelting the ore. Confused


RE: On=@Click problem - RanXerox - 05-16-2012 03:29 AM

I doubt that it would be that bad... EVERY equipable item in my server (I would guess several hundreds of thousands of items) has a LOT of code (over 400 lines) in the @ClientToolTip trigger and it doesn't appear to be overly lagged.


RE: On=@Click problem - darksun84 - 05-16-2012 07:22 AM

With client 7.0.15.1 @click works , i'll try now with the latest one

With client 7.0.25.6 works too.


Well i have tooltips disabled Big Grin


RE: On=@Click problem - Gil Amarth - 05-20-2012 07:28 PM

I have discovered "my problem".

When you have tooltips activated, On=@Click doesn´t work on dynamics objects, the tooltip fires before. When you set an static object and disable .GM (GM off). Then there is no tooltip and @Click fires normally. Smile