I am looking for a script to loop a sound while the player is moving. I can’t have the sound just play while the player is holding down a movement key, because of the sliding mechanic that I have. Is there a way to loop the sound while the acceleration is greater than 0? Also a script to not play the sound while not on the ground would be helpful.
now you have to find a way to determine whether you are touching the ground and set the grounded bool accordingly, for example check whether your collider intersects with a collider of an object with tag “Ground” etc.
Thank You for your help! :D
– Aerilan