Back to CharacterControllers
Posted by Aardvajk, 16 April 2014 · 370 views
Dumped the 2D game. It was going okay technically but just wasn't fun to play so had to make the decision to scrap it.
Back determined to write a 3D platform game again, so back to grappling with a 3D character controller. Learned a few tricks in the 2D game to do with raycasting to find the floor for handling slopes, hopefully will make this more successful than last time. CC's are a nightmare to get right.
At least I made a reasonable model as part of the 2D game that I can use in this one when I get to that point.
Have written a simple level editor that should be able to be expanded as this develops.
But until I can get the capsule behaving correctly with slopes and so on, no progress in any other area.
I have my own GJK implementation working fine as is - the character can be moved around with WASD and R/F to rise/fall and collides and responds correctly to the level geometry, and it is set up to be able to do raycasts but I've had a few dummy runs of trying to get slope behaviour working well with gravity and so far it has all ended in tears.
The key seems to be to only apply gravity when you are not grounded, but the distance to the ground is different for a capsule depending on the angle of the slope, which makes it tricky. I also want to have a maximum climbable slope angle and have steeper slopes block the character but still allow sliding. Its a nightmare. Nobody understands my pain.
I will battle on. Victory or death.