Search Unity

Create a surface that reflects other objects

Discussion in 'Physics' started by unity_5j21GR89l0bJLQ, Jan 7, 2019.

  1. unity_5j21GR89l0bJLQ

    unity_5j21GR89l0bJLQ

    Joined:
    Jan 7, 2019
    Posts:
    2
    Hello,
    I'm a beginner with Unity and i'm searching to create (in 2d game) a surface that reflects others objects, for example a ball will bump in the opposite direction and will not loose energy.
    Should i use a specific component (wich one ?) or create a script that trigger on collision event ?
    Thank's in advance.
     
  2. SparrowsNest

    SparrowsNest

    Joined:
    Apr 6, 2017
    Posts:
    1,273
    I was sure you're talking about mirror reflection.

    I think setting drag & friction to 0 and min, bounciness to 1 and max should solve it no?
     
  3. unity_5j21GR89l0bJLQ

    unity_5j21GR89l0bJLQ

    Joined:
    Jan 7, 2019
    Posts:
    2
    setting friction to 0 on the physic material of the box solved it thanks !