unity 4.3 stealth tutorial

Hi, It’s widely known in the forums that the stealth project has a lot of outdated aspects to it if you’re using unity 5. But when it says on the project download site https://www.assetstore.unity3d.com/en/#!/content/7677 that the tutorial requires 4.2 or higher and I have unity 4.3 I don’t expect there to be an endless amount of issues.

I just got through the PlayerMovement script and my player is stuck in idle mode regardless of what buttons i press and and error message says “Sneak key not defined”

I already fixed a few incompatibilities myself with CCTV animation and doors but this is getting ridiculous. If the download site had said only works for unity 4.2 then fine, my bad, but 4.2 or higher!?!?!?!?! I already knew unity 5 wasn’t going to work for this project but clearly unity4.3 doesn’t either.

Does anyone know about movement script issues for unity 4.3?

This should really be updated, if not the either project then at the VERY least the information on the download site!

open the input manager, define an input called “Sneaky” and assign it the key you want

1 Like

Thank you, I think my frustrations had me all confused there for a while. Of course I have to define sneak in the input manager !!! Thanks a lot my friend :slight_smile:

It worked :smile: expect my player doesn’t move, he just reacts with the right animations for the right keys and points in the right direction. So we’re getting close. Do you know why my player stays in the same spot when I press the move keys?

*Except

iirc the movement in that tutorial is handled within the animator based on the root motion of the animations, check that root motion is ticked in the animations.

1 Like

Thanks so much for your help. I haven’t tried this before so just to clarify:

I have imported my own animated character. The animations I made with it are “loop cycles” that don’t have forward motion. Could that be why my character doesn’t move since this tutorial is based on the root motion of the animations?

I tried checking the boxes but nothing changed.

ah… ok, if the animations don’t contain any forward motion and the project assumes they do it will indeed just stand there.

I would image the easiest way to fix that would probably be to change the animations (assuming you made them yourself and know how to do that), the other way would be to change the code structure to handle the motion in some other way (which might be tricky if you are new to coding and trying to learn from the tutorial project).

1 Like

Wonderful!!! I know exactly how to change the animations and yes I made them myself :slight_smile: That should do it, thanks a lot for all your help and the link, it really helped me :smile::smile::smile::wink:

Update: I changed the animations to have forward movement but in Unity that forward movement keeps starting from where the player is when the game starts. So it loops and there is forward movement but as soon as the animation is over and ready to start new loop, the player is back to square 1 so to speak.

Meaning that didn’t fix the problem, the player still has no movement when I press W,S,A,D or arrow keys, only the animations with their now incorporated forward movement is activated.

I don’t know if it’s an issue with the script or what but I’m confused now. Nothing is easy in Unity I guess!

Any ideas?

UPDATE UPDATE : :smile: I got the character to move now big selecting the root joint in “Rig” on the character but the mesh deforms in the face when I move around, however now I can move around, yeeeaaah ! :smile: little by little Im getting there. Any ideas as to why the mesh deforms once root joint is selected?