The easiest way to do it would be to simply add a alias to the command, and put it on your quickslots. As far as actually coding it yourself - this is what you'd need to do.
1) Find the name of the function that is called when you type in the slash command
2) Create a Turbine.UI.Lotro.Button, and place it at the coords you want it at
3) call the above mentioned function on that button's onclick handler
Being able to move it around is an entirely different ballgame that would entail
detecting whether alt, shift or ctrl is being pressed - depending on what modifier you want to "unlock" the button's position
setting whether your modifier is being pressed as a variable
having your button's "MouseDown" event handler check that variable, and then setting another variable as a flag to allow movement
if that flag is set to true (modifier pressed, and mouse button is down over the button, then change the button's position, relative to the mouse - on that button's MouseMove handler.
Obviously MouseUp and KeyUp handlers would be used to set the above mentioned flags to false.
Then of course, you have to keep in mind that if the author's plugin hides itself when you press f12, that you would have to put that button as a child of whatever window is hidden on that event. Otherwise, you'll still see that button after hiding the UI
Also, for best results, you'd probably want to use a Turbine.UI.Button instead, providing your own images for the three states (up, down and over) - as that way you'd be able to do a circular button, instead of the standard LotRO button.
|