x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Office Holiday

Epic Games' offices will be on holiday from June 22nd to July 7th. During this period support will be limited. Our offices will reopen on Monday, July 8th. 

UMG - mouse over / mouse off

Hi all,

I'm trying to implement a system in a strategy game where you can mouse over either a character or a UI element to cause an information panel to appear on the screen. Then when you're no longer hovering over the character or the UI element, the information panel disappears. This is pretty easy for the character side of things, as I can just use the OnBeginCursorOver and OnEndCursorOver events to turn the information panel on and off.

However, I'm not so clear on how to do this for a UMG user widget. I know that borders have a OnMouseMove event, but I don't think that that can be used to detect when the cursor leaves the border's space. There is also a "IsHovered" node present for user widgets, but I think that only really works for buttons.

What is the recommended way to handle detecting whether or not the cursor is currently hovering over a UI element?

Product Version: Not Selected
Tags:
more ▼

asked Feb 13 '15 at 12:47 AM in Blueprint Scripting

avatar image

evillego6
191 20 20 25

avatar image J. J. Franzen Mar 25 '15 at 07:09 PM

I would also like to be able to do this. Anyone have any tips or pointers? Google only provides a lot of people asking how to do this, and no solutions. For games that aren't FPS/TPS, this kind of functionality is not rare. Surely someone out there has done something like this? Right? Beuller?

avatar image Variss May 30 '15 at 06:33 AM

I've been thinking on how to do something like this for my own project. One possible option would be to use a float timer variable set to something very small (i used 0.05 seconds). Each tick it counts down, and if it hits 0, make the information panel disappear.

In the borders 'OnMouseMove' event, have it reset the timer to 0.05, that way, while the mouse is inside the border, the timer will keep getting reset and will never hit 0. Once you move the mouse outside the border, the timer should hit 0 and remove the information panel.

If anyone has a better way of doing this please share! Cheers!

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

HI Guys

Something like this might get you started.

alt text

Narg

capture.jpg (32.7 kB)
more ▼

answered May 30 '15 at 11:24 AM

avatar image

Narghile
1.7k 74 38 110

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question