Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

The sphere keeps falling through the floor.

Discussion in 'Getting Started' started by nazanin_z, Oct 21, 2018.

  1. nazanin_z

    nazanin_z

    Joined:
    Oct 21, 2018
    Posts:
    1
    I just finished the second video of the roll-a-ball tutorial but my sphere(player) keeps falling of the Ground. What am I doing wrong?
     
  2. Bill_Martini

    Bill_Martini

    Joined:
    Apr 19, 2016
    Posts:
    445
    Ok, so the sphere is falling. That means there is a rigidbody component attached to the sphere. The ground needs a collider component attached to it so the physics engine can prevent it penetrating the ground. Review the video again and I'm sure you will see the author add a collider to the ground. See Add Component in the inspector pane.
     
    nazanin_z likes this.
  3. Green11001

    Green11001

    Joined:
    Apr 14, 2018
    Posts:
    397
    They both need to have a component of type collider (Sphere collider, etc).
     
    nazanin_z likes this.
  4. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    20,759
    Check that you've added colliders to both objects like the others have mentioned. After that check and make certain that the colliders are not already intersecting. In the tutorial the ball is moved a little ways up but you may need to move it up a bit more if the ball's collider is intersecting the plane.
     
    Last edited: Oct 22, 2018
  5. taralees

    taralees

    Joined:
    Aug 29, 2014
    Posts:
    41
    this is a Maze game - Both the floor and the ball have colliders on them so when I roll the ball it touches the the wall and so I tilt it back in a different direction the ball falls through the floor