True First Person

Okay guys, this is my first post. I’ve been ripping my hair out over this for a month, trying every possible solution that I think could be viable. I tried to not post about this, I wanted to find out on my own through research but I can’t find a single tutorial, walk-through, step-by-step, or any documentation on the subject at all. I have a humanoid mesh that is rigged with a normal human-armature. IK’s for the lower leg and the lower arm chain length of two each. I can not figure out for the life of me how to make a first person shooter where I can look down and see my character’s body/legs when running/standing. Traditional FPS tutorials have you parent the arm rigs with an object, that is also parenting a camera, and with a mouselook you get the illusion that you are looking up and down while also moving your arms to aim.

For a full human armature/mesh, I can’t figure it out. I’ve tried using two separate armatures for the one mesh (separate 1-bone rig for the head apart from the body rig, a separate head/arms rig apart from the body rig.) But everything was too glitchy and it never allowed for the mesh to actually be controlled by the two correctly. If I could just move the head of my player for camera movement with the mouselook code, and somehow move the arms along with it to aim, I think that’s all I’d need to do this. I’ve tried very hard with nothing to show for a whole month but a bad headache every night.

I’ve tried thinking of using constraints like copy rotation on the arms to the camera/head, but of course that won’t work in BGE as far as I know. There must be a way. I feel like I’ve got a great idea for my game and I’ve actually got quite far with it in Unreal Engine 4. But I want to do it in the BGE, I believe in the engine and I love blender and want to make it work. There’s got to be a simple way to do this. Could anyone help a newcomer out? I’ll learn more python if I have to. I’ve been wanting to anyway.

Thanks Guys.

BTW, I’m using TheTimster’s guide on an FPS for my basics layout. I know I want it to be true first person so I can see my body, but I might want to implement optional third person view (Or only for certain parts like when taking cover from fire.)

Okay so I still really need help. With no replies here, I just went with faking it. I cut my character into two pieces- the arms separate from the lower body, and the player just has no head. This has been fine, as I parented the arms to my dynamic object, and parented the lower body to the dynamic object. But now my game is progressing a lot, the environment and all, and the shadows are just such a buzz kill when play the game. There is clearly no head shadow, and the arms, no matter how I place them, are sometimes very clearly separate. I could opt for casting no shadow, but its a really nice touch to the game and I don’t want to lose it.

I guess I should clarify what I would need. I need to figure out how, with a full, whole body armature, to get only the arm bones and the head bone rotating with the camera that has a mouselook. I can parent a camera to specific bones in an armature. But I can’t seem to figure out how to parent specific bones to a camera, so that only those bones move/rotate when the camera does.
Please somebody help me out with this. I don’t know if there is some sort of constraint I can use or what, but I need this to progress much in the game.

I think you’re over-thinking the problem because you have your head full of different possible approaches that you think might work, and they’re getting more complex as you struggle for a solution. I’ve been there many times! :stuck_out_tongue:

I’m not the best person to answer this, but i you supplied your blend file, you might get a helpful response from someone who is. It’s hard to determine what your problem might be, without it.

Do you want the legs to stay in place while the top part of the player moves with the camera?

There’s an armature actuator (only shows up on armature objects) which can be used to activate some of the constraints which you can apply to armatures. One useful constraint is the track to constraint.

Add a bone to your character’s waist. Parent the torso bones to this bone. Give this bone the track-to constraint. Make it track to an empty.
Add the armature (run armature I think) actuator to your character’s armature. Make sure when animating your character that you don’t key frame this bone. An option is to leave the torso bones connected to the waist but parent only the hands to the tracking object. Add IK to the arms if you do this.

Use python to move the empty which is being tracked. One way is to parent that empty to the camera, another way is to make it copy hit position of a ray cast by the camera. It’s up to you.

You may want to use python to make sure that your mouse look has limits, so you can’t look directly up, down or behind yourself. These positions would give the armature a strange deformation which would make your character look crazy.

Smoking_mirror, I’m having trouble actually putting the track to constraint onto the neck ( I’m not worried about the torso, just the head and the arms, the mouse look will move the dynamic object left to right, which the armature will be parented to.) When the track-to is applied, I can’t seem to get the head straight. It moves, and I’ve tried all of the combination of settings for the track-to, like “which axis is up?” " local, world, local space with parent?"

Also, its seems like I can only parent the empty (or anything) to a bone, I can’t parent the hand bones to the empty.

Josip Kladaric,
Yes, that’s exactly what I need. Rather, I need to be able to move just the head and the arms with the camera. (z axis), mousescripts can move the whole armature on the x axis (left right).

Attached the .blend

Damnit! I can upload everything to this sight except a freaking .blend. I don’t understand.
https://drive.google.com/open?id=0BwbISrgfr8z7SFZycnJkMEZYMnc

mwkazlow, you can’t parent the hand bone to an empty because it’s already parented to another bone in the chain. You need to find a work-around.

lol, no kidding.

Well it sounded like you didn’t understand that.

Use a templete: http://www.blendswap.com/blends/search?keywords=fps&is_fan_art=1&blend_license=&render_engine=&sort=downloads&direction=desc

Yeah, I looked there. No templates like that, all their FPS templates are just arm armatures. Their third person games are not even close to what I need. I’ll figure it out maybe, thanks for your help.