Hello, I’m trying to increase the travel distance during my slide anim but despite the big change in variable the speed even decrease
And this is what the print is printing
I don’t if it’s normal but it’s painfull ^^
Hello, I’m trying to increase the travel distance during my slide anim but despite the big change in variable the speed even decrease
Instead of looping the timer, maybe set its time to the duration of the slide animation? Then have the event that starts the slide also set a ‘IsSliding?’ bool or some such along with the new walk speed/acceleration. Could use this bool in the main input events to modify the input scale via select float node or branches.
The custom event called when timer finishes would then just set the bool to false and set speed/accel vars back to normal.
As it is, it could be the custom event’s Add Movement Input node might simply be fighting with your primary input events.
Thanks for the answer and sorry i didn’t put the full code because i wanted to focus on the problem part. I already have a “IsSliding?” var all set up.
I’ve also added some prints right before and after the movement input to see if the walk speed was changed somehow.
Hmm, not sure why it would be slowing down like that. Might be a good idea to switch to the enhanced input system. With the extra execution pins that provides versus old input actions, you could quickly set the slide speed once on Started instead of setting it constantly in a ticking loop, and use the Triggered pin to feed the move input while the button is down. It also has built-in options for holding buttons so you could also call the end slide function when the hold threshold is reached instead of relying on the anim notify.