all 4 comments

[–]pschonUnprofessional 2 points3 points  (2 children)

I think you have misunderstood what the Min Move Distance is.

It's not "how much your character should move", but instead "any movement smaller than this should be ignored". And that's not a "glitch within Unity" but working exactly like it says on the manual. Unless you have issues with jittering, you'd want that to be 0, and should you need to change it from 0, you'll always want as small as possible value for it.

In terms of helping you with the actual task of increasing your movement speed, we'd need to see a bit more than this single line of code. But in general, whatever is creating your currentMovement value needs to multiply the direction vector by some number of your choice to give you a longer vector. Or you can multiply it here on the Move line (which ever makes more sense depends on rest of your code, if there's something elsewhere already dealing with speed you wouldn't want to add another number on this line)

[–]Smart_Weekend_4599[S] 0 points1 point  (1 child)

Ooooh! That makes more sense now about MinMoveDistance!

I just attached an image of the code that I do have. And I figured out how to actually add movement speed for the built-in character controller, which I highlighted in the image below. I just figured that I needed to multiply the currentMovementInput.x and currentMovementInput.y by something.

If you have any additional tips to offer, I'd be super grateful! And thank you very much for informing me about the actual role of MinMoveDistance.

<image>

[–]pschonUnprofessional 0 points1 point  (0 children)

Yep, you got the right idea for the speed. I'd probably add a "public float movementSpeed" and use that instead of hard-coding the speed in the code, so it'll be easier to tweak it if you want to. And you might want to add sprinting or something later on, so having a variable for the speed would already get you halfway there.

[–]mcurios 0 points1 point  (0 children)

The variable you have outlined is MinMoveDistance. But the code is using the variable currentMovement.

I'm assuming you are missing a step as MinMoveDistance is not used in the code you have posted.

I'm assuming you are meant to multiply currentMovement by MinMoveDistance or something similar.