So basically I want to know if it’s possible to have Begin Cursor Over event fire continuously like an Event Tick. What I want to do is hover the mouse over a mesh and have something change (in this particular case setting a highlight material) for as long as the mouse cursor is on the mesh.
If it’s not possible, I’d like to know of any method to achieve the desired effect.
You can change a boolean to true, when the cursor initially comes over the mesh
Then in Tick, do your thing only if that boolean is true
On Mouse move away from the mesh, set the boolean to false
But this is a singular action that does not require doing something 60 times per second, right? That’s unless you’re pushing a progressing parameter into a dynamic material. Could you clarify why Begin Cursor Over is not sufficient? However, if you must have it your way, gatingTick would work:
And so would a conditional Branch mentioned in the previous post.
Thanks a lot for your suggestions. The problem is that End Cursor Over triggers as soon as I move the mouse over the mesh. I’m wondering if it could have something to do with the mouse sensitivity or something being wrong with it.
The issue is elsewhere. This part works fine, and trying to force a solution with Tick will only create more problems. Do double check / post your script.
Under regular circumstances, the most mundane setup:
The question here is - what is irregular in your case? I’d investigate that.
Again, it’s most likely not about the basic material setup, this part is fine. Something else possible interferes with the cursor - at least judging by the description alone.
use breakpoints to ensure the data actually flows the way you expect
print / debug values you’re pushing into the material
you’re using an Overlay Material - that’s definitely irregular, perhaps it’s something related to that - try it without it. It will at least allow you to narrow the issue down or dismiss it being the cause.
debug mouse tracing - see what and when are you actually tracing against
Okay so the problem was that I fed a material instance not a material to the parent input in the create dynamic material instance node. Now it’s working well, but I’m wondering if there is a way to keep the highlight material even when the cursor moves over the mesh?