Why does mouse wheel fires both output?

Hey Guys. I’m using mouse inputs. But, there is a doubt. Whenever I use mouse wheel both the pressed and released output fires at the same time. I think released should output only when I stop scrolling like any other button.

I’m not sure. If anybody knows the reason behind this. Please tell me.

Thanks.

Hi ,

These nodes are specifically designed to detect each “click” on the mousewheel, which has no way to be held until release (unlike the middle mouse button functionality, which acts as normal button inputs). Each time the mouse wheel scrolls up or down, it will run the pressed and released. It is typically better to run all of your functionality on the “pressed” unless you need specific information to be run afterwards.

@ I’m starting a timeline with scroll pressed, so how can I stop the timeline midway when the player stops scrolling.
I’m doing this as an experiment for camera zoom-in&out. There are other ways like changing the length of the camera boom by a certain value.
But, it would have been great if the scroll released fired only when the scrolling is stopped.
Thanks.

try placing a retriggerable delay with a small value on it. This will reset every time you run the scroll up. If the retriggerable delay is allowed to go through to the end, then run the end timeline functionality you are trying to do.

Thanks @ that did the job.