by

Complete Youtube tutorials series can be found here

https://www.youtube.com/playlist?list=PL0HP3BNvjjHdroo3lSZ4o5qatHQJ1rH8Z


Table Of Contents

In here you will find links to the proper sections of this documentation

Table Of Contents

Setting up a new project

Start using Pocket Ragdoll

Floor

Grabbabble Objects

Player

Pocket Ragdoll Controller

Player Input Controller

One Hand Controller

Player Equip

Troubleshooting

My Player doesn’t jump

My Player grab item is strange

My Camera doesn’t follow the player


All this information can be found in our Youtube Playlist

Setting up a new project

When setting up a new project, first we need to inject the Pocket Ragdoll settings.

On Unity’s upper menu, go to Tools  -> PocketRagdoll  -> PocketRagdoll Settings Injector

This will open up a new window

This will apply general settings in your project, such as the new Layers to use ( Player  and Ground ), the CanBeGrabbed  tag and some Physics changes on the project:

If everything is ready, you will see a log in the console with the message “ Pocket Ragdoll project settings has been successfully injected

Now you are done with settings!


Start using Pocket Ragdoll

Floor

Once the Project Settings are done, you can start preparing your project. Start by adding a 3D model (we recommend a Plane or a Cube) to act as a floor. Make sure this new object has a collider attached to it and if it has a Rigidbody make sure it set to “isKinematic” since it doesn’t move and we don’t want gravity on it.

Make sure that this new object has the layer “ Ground


Grabbabble Objects

After that, add any object on the Scene that you want to grab . Make sure this object has the CanBeGrabbed  tag, a Collider  and a Rigidbody  like in this picture:

Player

Pick any 3D model you have for your player/character. We use any downloaded from mixamo.com  but you can use any other. Make sure it has a Humanoid  Rig .

Drag the new model into the Scene so it appears in your Hierarchy.

Now that we have the base for the player we can start with the Pocket Ragdoll Binder which helps creating a ragdoll player. Open the Binder window by going to Tools  -> PocketRagdoll  -> PocketRagdoll Binder


This will open a new wizard window:

Note that on the next images you will see an option “ From scene object ”. This was for the previous Pocket Ragdoll version so don’t worry.

  1. There are 3 different types of templates for you to choose from. Don’t worry if you don’t know which one is yours since this are only a template to make it easier to map the colliders to your player model. By default “ Normal ” is chosen.
  2. Drag your main model Game Object on the “ Model Container ” field
  3. Click on the “ Instantiate From Template ” button

This will create another Game Object on your Scene and also enable new fields on the wizard:

The next step is to map using the scale and move tools the “ PocketRagoll ” child Game Objects into your model in your scene. The blue objects map the colliders to be used in your player model so make sure it maps correctly. For example, one arm should look like this:

Don’t worry if it doesn’t match 100% but make sure it’s as close as possible to your model. Note that one can change the colliders later.

After making all the changes on the template, you can collapse the PocketRagdoll in your hierarchy to make some space for your model. Expand you model so you can see each component properly.

Start dragging the corresponding Game Objects  from the hierarchy window to the Binder window . Each field is properly named so it fits your model. Note that one can expand/collapse each section.

One should get something similar to this:

Once you are ready, just click on the “ Bind PocketRagdoll to Model ” button. This will make the Template and your model Game Object merge and apply all the necessary scripts to it. This means that now your model is under the PocketRagdoll Game Object.

If everything goes correct, you can se a message in the Console saying “ PocketRagdoll has been binded ”.

You can note that there are new scripts that have been added. Below you will find some descriptions to them.

Pocket Ragdoll Controller

This script is the ❤️ of Pocket Ragdoll. First it contains all bones mapped to your model. Usually you don’t need to change them.

Below them you can find the bones and rigidbodies of the hands under the “ Hand Dependencies ”. As with the upper bone sections, you shouldn’t need to change this ones.

Afterwards you can find the “ Use Controls ” checkbox, which enables/disables the control input on this player. This is useful if you have more than one player in the scene.

Later we have the player and ground layer masks. This should be the new layers created by the Injector on the previous step .

Finally we have some settings that you can change to fit your game. Play with them and see the changes.

Player Input Controller

This script is the one in control of which input to use. It’s configured with the default settings on the “ Project Settings ” -> “ Input Manager ”. It also has a checkbox to enable/disable the Punch  feature.

In here you can also set which hand to use: either Left  or Right  hand

One Hand Controller

Controls the force and stiffness of the hand limbs when reaching and punching.

Player Equip

This script is the one in charge of grabbing/throwing and equipping an item to the player. There’s no need of changing it’s values.

Now you are all setup! Go to Play Mode and start testing your new Ragdoll player!

If anything is unclear, you can also find our Youtube Playlist  where we show this steps.

Troubleshooting

  1. My Player doesn’t jump

Check that on the feet Game Objects that have the “ Feet Contact ” script attached to have the “ Ground ” layer mask assigned.

  1. My Player grab item is strange

Make sure that on the Player’s script “ Player Equip ” are assigned the direct childs of the “ PR_LeftHand ” (and “ PR_RightHand ”) Game Object. Usually is the container of the “fingers” Game Objects. If there’s no child present in your model, create an Empty Game Object  as a child of the “ PR_LeftHand ” and “ PR_RightHand ”.

  1. My Camera doesn’t follow the player

If you are using Cinemachine or any script that makes the camera follow the player, make sure your target is set to the “ PR_Root ” child Game Object.

For any further question not covered here feel free to contact us at support@berserkpixel.studio