A request for all plugin authors
Hello all,
I have a (relatively) small request for all you amazing plugin authors out there. If your plugin has a visible toggle button (or any other visible aspect, really) associated with it, could you please (if possible) make it so this disappears like the rest of the UI when F12 is pressed? It would sure make taking screenshots a lot easier. I realize that I could simply unload the plugins in question, but sometimes I'm trying to capture something in a split second and...well...you get the idea. Thanks in advance, and please keep up the awesome work! |
Quote:
Code:
self.KeyDown = function(sender,args) Now, for both the OP and other authors, there is one caveat. The action alone only tells the author whether someone has pressed the key that shows/hides the UI, with no information pertaining to the actual state of the UI at the time. Now with this (unlike UI positioning) it isn't so bad, as it is unlikely that someone would be able to load a plugin with the UI hidden. Even still, the author should provide some option to assist the user in "syncing" the plugin with the game. |
Or, if you use the Dragbar class - this seems to be automatic!
|
Yup, I did this for the travel window's toggle button. It is a fair request.
|
Quote:
|
Is this number/amount the same for all nationality of keyboard.
(args.Action == 268435635) because i cant get it to acknowledge that the f12 key has been pressed. |
Quote:
|
Quote:
|
Ty for your replies. I noticed the typo and tried SetVisible and IsVisible. Also im aware of the keybind and it is F12 for me, so thats not the issue, and as youve pointed out to me that its nothing to do with a keypress signature, rather the lotro code. It leaves me wondering why it aint working for me :s
I placed a Turbine.Shell.WriteLine command in its structure but got nothing. |
Quote:
Did you put the WriteLine inside the If statement or just inside the start of the function definition - if it's just inside the function, you should get responses from any action event, such as showing bags, hitting escape, etc. If you aren't getting that, then you need to check where you are defining the function and be sure you don't already have another .KeyDown function defined elsewhere for that control. Oh and be sure you didn't SetWantsKeyEvents(false) for that control. |
self.myplugin was changed.
writeline i placed in a few places. before, in and after IF statement (nothing) writeline placed outside this function ( i got spammed ) This function is defined in the update part of the LUA, which gets called alot. SetWantsKeyEvents havnt been used |
Quote:
|
Quote:
so in the case of my original example, you would need to precede it with the following line for it to work: Code:
self.SetWantsKeyEvents(true); |
K, thanks. Ill give that a go then :)
|
Ok, i got it to work and tweaked it to do everything i need it to for Mouse Cursor Highlighter Advanced.
Decided to post my part of the code for others to get an idea of what to add/do..
Code:
self:SetWantsKeyEvents(true); |
Quote:
Thanks for clueing me in, Garan! Your plugin is insanely awesome!! |
In case it helps, I'm using the following in my plugins, so I can manage my windows generically for F12 and Escape (the actual version I use also handles CTRL+\ for my drag bars, but I stripped that here):
Code:
import "Turbine.UI"; Note: I use weak references to 'managed' windows so as to not prevent the garbage collector from getting rid of unused windows. |
All times are GMT -5. The time now is 05:47 PM. |
vBulletin® - Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
© MMOUI