T0X1N Posted December 31, 2016 Share Posted December 31, 2016 I have noticed that when the character controller is crouched, the controller's step height is ignored and will not step over anything. Am I missing something or is this a bug? Quote Website | Twitter | Facebook | Steam Play Our Latest Game: Relic Rogue Link to comment Share on other sites More sharing options...
Einlander Posted December 31, 2016 Share Posted December 31, 2016 Read the all the comments on this blog: http://www.leadwerks.com/werkspace/blog/120/entry-1575-einlanders-halloween-devlog/#commentsStart Quote Link to comment Share on other sites More sharing options...
T0X1N Posted December 31, 2016 Author Share Posted December 31, 2016 Thank you for posting this article! It really has some great analogy on the character controller and Leadwerk's scaling. Very helpful! This crouch issue is actually a real pain, and I am surprised this issue was not fixed yet since this article is more than a year old and it concerns a pretty crucial part of the engine, character controllers! I will have to avoid using the crouch commands because of the step height. It will be unnatural and a real annoyance to the player that they cannot step on things that is not higher than 8cm, although in my tests, I cannot step on anything above 1cm in height while crouching, which is ridiculous. Now, the problem is, how will I go about going around this issue? I have tried "SetHeight" to the controller, and that does not seem to work. I have tried to set the height to a very small number of 0.0005, and the controller is still not able to fit into an area that was previously accessible using the crouch command. I rather would not to not put up ramps for all of my steps and areas that there is any height differentiation, that will just be a real mess. **** EDIT **** I thought about it for a while and came up with a simpler solution... I will use the crouch command, although, I will only use it if the world tells I have to. So in my program, if the player crouches, it will simulate that the character is crouched as the camera will go in the crouched position, but the controller will not be crouched. It will only start crouching when it collides with a trigger zone telling the controller to start using the engine's crouch command. I think this is the better solution that I can think of. Although, there will need to be some work putting in place of all the zones where the character controller's crouch height is needed (IE: vents, small spaces, etc.)... but that is game development... Some good comes out of this way because the designer has more control of the player's crouching mobility. Meaning there is less chance that the player can glitch out the controller or map and get into spaces that the designer does not want the player to squeeze into. 1 Quote Website | Twitter | Facebook | Steam Play Our Latest Game: Relic Rogue Link to comment Share on other sites More sharing options...
Einlander Posted January 1, 2017 Share Posted January 1, 2017 You can raycast from the front and top of the character controller to the ground. And another ray from the bottom faceing front. If while crouched the bottom raycast hits something with an angle greater than 45, and the top ray has a correct step height, move the player up by step height + 1cm. The controller should take care of the rest. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.