Instynct 1 Posted June 24, 2013 I'm trying to set a control elements position from my dialog to my mouse location but I can't find any methods for getting the mouse cursor location. Any help? Share this post Link to post Share on other sites
samatra 83 Posted June 25, 2013 http://community.bistudio.com/wiki/displayAddEventHandler https://wiki.bisimulations.com/wiki/VBS2:_User_Interface_Event_Handlers Try onMouseMoving Share this post Link to post Share on other sites
Instynct 1 Posted June 25, 2013 (edited) http://community.bistudio.com/wiki/displayAddEventHandlerhttps://wiki.bisimulations.com/wiki/VBS2:_User_Interface_Event_Handlers Try onMouseMoving But that won't really work in my context, I just need to get the mouse position once, not every time it moves. I need to get the position inside of another event handler to set the position of a different control. Like this -> User clicks a button -> get mouse position -> set another control to that position. And another problem I'm having is the MouseEnter and MouseExit event handlers don't work at all.... Easily the worst UI system i've ever seen in a game. Edited June 25, 2013 by Instynct Share this post Link to post Share on other sites
samatra 83 Posted June 25, 2013 Save your mouse position with this event handler periodically into array and address this array elsewhere when needed. Share this post Link to post Share on other sites
Instynct 1 Posted June 25, 2013 Save your mouse position with this event handler periodically into array and address this array elsewhere when needed. I've tried this, the problem is the first event handler always starts before the one that can get the mouse position and there's no way to set priority to which one starts first. Share this post Link to post Share on other sites
samatra 83 Posted June 25, 2013 Are you sure you save it into proper namespace and global variable? Share this post Link to post Share on other sites