Are there any tutorials or demos on how to initialize and use the hkpFirstPersonCharacter? I'm making an FPS using my own rendering engine, and I can't seem to find this class being used anywhere. Should I use just the character rigid body instead? Thanks in advance, Daniel
hkpFirstPersonCharacter initialization?
Hello,
you could have a look here
It show a basic hkpFirstPersonCharacter initialisation code.
Regards
hey dude, that`s my code, lol.I`m sorry it`s very ugly code and I do not use ogre anymore, hope this code helps.
Hello, Sorry for posting your code, but I used it long time ago and find it usefull to understandhkpFirstPersonCharacter ! Regards
Hi guys, thanks for the replies, I got it working, but my only problem is the jumping function, when my character jumps, it's a very small hop, and happens about 2 or 3 times per key press. I have my chacter scaled up to be bigger, is there anything I need to change in respect to mass, jump height, or anything? Thanks! Daniel.
Did you change the height and radius of your charactercontroller?
Yes, I changed the height to 11, and radiusto 2. But the thing is even when it's the default height and radius, it still hops and looks terrible. I'm trying to look up character controller demos, but none really show anything special like this. Thanks again, Daniel
OK So I just changed the whole thing to pretty much what the character controller demo had, except with the first person controller, and it still does this. I can't figure out how to change this
Did you check the VDB? I am not sure what`s the problem, and be careful with the coordinatesystem between your render engine and havok, the demo make z up.
Yea, the VDB show's exactly what I'm experiencing. So I actually just implemented the hkpCharacterRigidBody and context instead of using the first person character and it seems to work just fine now. I feel like it may just be a bug in the first person code. I can't tell for sure though, because there's no demos on it.
Just thought I would mention that hkpFirstPersonCharacter just wraps the hkpCharacterRigidBody and does a couple things for you. Without digging in to this further, I would bet the reason for the small jump is that by default hkpFirstPersonCharacter scales the character gravity by 16 (which is common for most FPS-style games).
Regardless, we usually recommend most people use hkpCharacterRigidBody (or hkpCharacterProxy if needed) directly since hkpFirstPersonCharacter doesn't add much and the code is a little more clear if you have to set it up yourself.
Cheers,
Tyler



