Simple movement with collision?

So, I’m making my own blueprint for my character controller because I’m making a 3D platformer and I would would like my character to slide down slopes, struggle up slopes, and have more actual physics than simply stopping when it runs into a certain angle of slope. I tried adding sliding functionality to the existing character controller, but none of what I did was right - the sliding really needs to be a result of gravity, not a secondary variable.

Anyway, I am trying to add controls to a pawn, and I can’t figure out how to get collision working properly. I tried using the SetActorLocation function, but the pawn will just stop dead when it hits things rather than being displaced. I tried adding a FloatingPawnMovement component and using the AddInputVector function, and this works for just moving back and forth (it displaces the pawn up a hill nicely) but this has built in acceleration and max speed. I don’t want this. I just want to be able to set a spot and have my pawn try to go there, and if it can’t, it gets displaced around the curve of the object. Is there anything like this, or do I have to program my own collision detection too just to make this happen?

If anyone is familiar with how Unity does collision capsules - I want it to work like that.

I suspect there are some variables you should tweak inside the character movement component, but not sure which are.

I suggest you to read the engine code and try to find something like angular movement limitation or angular speed reduction inside the character movement component…

If you dont find something useful, you could change the friction values manually when entering each of these states

It’s not a question of friction. I actually had the 3rd person character moving nicely. What I want is, as the character runs up a hill, the momentum carries it further than it would normally go, and then gravity takes over and it slides back down. Or, when it’s running sideways across a hill, it moves forward while also sliding down. Or if it lands on a slope too big for it, it slides until it comes to a point where it would normally stick, and slide a little more.

The 3rd person controller is set up to be all or nothing. There’s an angle you set where anything smaller the character is stuck to the ground, and anything greater and the character is falling. If you run into a hillside, it just stops dead. I set up a second variable to slide the character and made the slope 90% (so it can essentially run up a wall, but the sliding variable will pull it down) and this KIND OF works, but it’s very wonky and unpredictable because it’s not tied into the actual gravity.

I would much rather make my own controller, but I need to know how to make the collision work properly. It doesn’t seem like there’s a basic collision option - which would be a bit of an oversight. As I already said, the FloatingPawn won’t work because it has acceleration and stuff built into it, so I can’t use it to simulate gravity since that would need its own separate acceleration from horizontal movement.

Sounds like your describing Mario 64 movement

I’m making a platformer, so that makes sense. How do I get proper collision without all the extra fluff, though?

I figured this out, actually! FloatingPawnMovement will work, I just had to set max speed, acceleration, and deceleration to 99999 - now it will just add whatever force I want instantly and then stop adding that force instantly.

Very good. I feel much better now. It’s nice to have full control of my character’s movements. :slight_smile: I’m gonna have this guy bouncing on trampolines and getting shot out of cannons soon enough. :smiley: