Events Begin/End Cursor doesn't fire when mouse is fast.
Im trying to use the events Begin/End Cursor in a Colision box. It works, but it just doesn't fire if you're moving the mouse too fast. I've been testing the ''speeds'' that trigger the event, and its kinda good for me, but i want to know if there is something to fix this.
asked Jan 03 '16 at 04:32 PM in Blueprint Scripting
This is a bit old but in case someone runs across this like i did. A higher framerate should help, but if you dont have one a solution(and the only one i can think of) would be to do the detection manually, on tick do a trace (to detect cursor begin/end cursor over, this is likely what the engine is doing anyway.) then
to save the previously known mouse location from the last tick and get the current position from this tick then subtract them from each other to get the difference, divide by 2 to get the half way point of that difference, then add it back to one of them to get the in between point(you may have to add it to whichever one is closer to 0,0). then do a trace from that position before doing the trace from the current tick. this should give you a in between trace but it will double the number of traces you are doing per tick. you can also add in a if statement and compare the current ticks mouse location from the last ticks mouse location and check the distance between them, if its too small dont do a extra trace, if its far enough apart then do the extra one. Depending you can even do 2 extra traces by dividing by 3, 3 by 4 etc. but i imagine this will start to get heavy depending on whats happening so testing required.
For most cases i dont imagine this would be vary useful but if you must get that in between trace(like a laser that cuts/hits all actors under the mouse) then this i think would be a suitable solution, though i cant say whether there is a better option or not, this is just the best i can think of.
Maybe a bit complicated? but if you need it you need it. if you can get by with potentially missing over some detections then im not sure id bother with this.
answered Aug 22 '16 at 02:48 AM
Follow this question
Once you sign in you will be able to subscribe for any updates here