Actually no. When I click and drag it they either:
1: end up in a folder I don't want them in
2: drop to the bottom where I don't want them either
3: ends up a child-trigger/alias/etc
Mudlet features and API requests
Re: Mudlet API requests
You don't drag it into, you drag it between them.
Re: Mudlet API requests
Started on this. Several ways to go about implementing this...Widjet wrote:Okay, probably dreaming with this one, but would it be possible to have events for mouse movements or at least mouse entering/exiting specified areas?
I can imagine something like:
Either a) use event tracking on the whole main window and report every movement as a Lua event + have a framework in Lua that calculates whenever it was in any of those bounds
b) same, but do the calculations in Mudlet and only raise events then
c) use per-label tracking and only report mouse movements as events then
I'm not sure how efficient is the event system for this, but initially I'll go with option 3 - since it somewhat covers the selection part for you already. Further discussion on this should be branched off into a topic of it's own, I suppose.
Re: Mudlet API requests
Added a sysWindowMouseMoveEvent event that has the label name as the argument. Fires whenever the mouse is moving over labels. If you can compile code, it'd be great if you could test this - my branch is currently at https://github.com/vadi2/Mudlet
Re: Mudlet API requests
I will when I get a chance, I'm a bit busy until after the Easter weekend, though.
-
- Posts: 9
- Joined: Tue Nov 02, 2010 12:34 pm
Re: Mudlet API requests
Would be nice if feedTriggers function would have parameter, that simulated line is not added to main window at all.
Currently, i was trying to re-use all triggers for parsing log file of mud sessions to collect some statistics. Log files can be big, millions of lines. I don't want those line to be visible in main window nor in log files, so gagging them is not an option. Also, i experience crashes when so many lines are fed. And i don't know how safe is such feeding in terms of that at this same time other lines can come from mud, and i don't want them to interfere with current log's parsing.
Currently i have to resort to duplicate triggers i want manually in code, parsing log files line by line and matching against those patterns i want and calling appropriate functions (which is actually more or less what mudlet itself does). This solution is very fast and works ok, but not elegant because of this duplicating.
Currently, i was trying to re-use all triggers for parsing log file of mud sessions to collect some statistics. Log files can be big, millions of lines. I don't want those line to be visible in main window nor in log files, so gagging them is not an option. Also, i experience crashes when so many lines are fed. And i don't know how safe is such feeding in terms of that at this same time other lines can come from mud, and i don't want them to interfere with current log's parsing.
Currently i have to resort to duplicate triggers i want manually in code, parsing log files line by line and matching against those patterns i want and calling appropriate functions (which is actually more or less what mudlet itself does). This solution is very fast and works ok, but not elegant because of this duplicating.
Re: Mudlet API requests
You could open a second instance of Mudlet, not connect it, and parse it then?
-
- Posts: 9
- Joined: Tue Nov 02, 2010 12:34 pm
Re: Mudlet API requests
True, that is another possibility, seems to work good enough at first glance.
Re: Mudlet API requests
Okay, I've had a chance to test this.Vadi wrote:Added a sysWindowMouseMoveEvent event that has the label name as the argument. Fires whenever the mouse is moving over labels. If you can compile code, it'd be great if you could test this - my branch is currently at https://github.com/vadi2/Mudlet
It doesn't work, because the TLabel's mpHost variable is always null, because TLabel's setScript function is never called (so far as I can tell). I'm not sure where setScript should be called, perhaps in createLabel?
Re: Mudlet API requests
Er... Worked in my testing. I'll give it check on a new checkout.