Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: nxgravity on January 22, 2015, 01:04:34 PM

Title: Prefab Interactions
Post by: nxgravity on January 22, 2015, 01:04:34 PM
Hello,

I have a Prefab character imported into my scene. I also have a Character Controller and a Rigidbody objects applied to the Prefab. I also have a simple Terrain my my scene with the terrain collider applied. My problem is, my prefab character keeps falling though the terrain, and any other objects that may happen to be below him.

My Prefab is composed of several smaller assets, and I've attempted to apply a ridgidbody to each of the sub assets, but the Prefab keeps falling. I can, in the same scene, add a 3D object (capsule as an example) and once I apply the rigidbody to the object, it doesn't fall though the terrain.

Sorry if my terminology is a bit off, I'm new here and to Playmaker.

Thank you for the help,
Rob

**Edit** I also made sure the Prefab object is above the terrain.
Title: Re: Prefab Interactions
Post by: wheretheidivides on January 22, 2015, 05:39:51 PM
Is there a collider on the guy?  I don't see a capsule collider.  That is what interacts with the terrain collider.

"I can, in the same scene, add a 3D object (capsule as an example) and once I apply the rigidbody to the object, it doesn't fall though the terrain"

Because when you create the object, it has a collider attached to it.
Title: Re: Prefab Interactions
Post by: nxgravity on January 23, 2015, 02:26:04 PM
Is there a collider on the guy?  I don't see a capsule collider.  That is what interacts with the terrain collider.

"I can, in the same scene, add a 3D object (capsule as an example) and once I apply the rigidbody to the object, it doesn't fall though the terrain"

Because when you create the object, it has a collider attached to it.

Thank you for the reply.

When I add the capsule collider, things become odd. My character walks at a super speed while bouncing around. Sorry if this is more of a unity question, I just can't seem to get this prefab to walk without falling though the ground of break dancing like a fool.

Thank you,
Rob
Title: Re: Prefab Interactions
Post by: wheretheidivides on January 23, 2015, 02:41:54 PM
Take off the charcter controller.  See what happens.
Adjust the capsule collider so it is around the player and not below the ground. See what happens.

Yeah, it's not a playmaker question but it's really simple to answer.  Put a capsule collider around your guy making sure it does go below the surface.  You may need to raise the guy up a tad so he falls to the ground.  try that.  Move him up a few feet and then hit play.  He should fall to the ground.  The colliders are now working.