Search Unity

2D - Prevent bounce on ceiling?

Discussion in 'Physics' started by emde, Sep 15, 2016.

  1. emde

    emde

    Joined:
    Aug 1, 2015
    Posts:
    6
    Hi, I'm new with physics in Unity. I'm trying to get an object that when "jumping" using Rigidbody2D.AddForce() and hitting a ceiling (top of screen) Box Collider 2D, will simply stop moving up and eventually fall down. Right now when hitting the ceiling collider, the object bounces down immediately. I've tried different physics 2D materials and setting bounciness to 0 but it doesn't appear to make a difference. If anyone has ideas on how I can get the physics to work without the bounce on the ceiling I would appreciate it.

    Thanks!