Search Unity

How To Add Brightness/gamma Functionality In Unity 2d

Discussion in '2D' started by misanthropowitsch, Apr 12, 2019.

  1. misanthropowitsch

    misanthropowitsch

    Joined:
    Sep 30, 2016
    Posts:
    23
    Hi Guys,

    I recently tried to add Brightness/Gamma UI Features to my prototype, but I failed miserably. On searching for a way to do it you always stumble upon 3D tutorials which don´t fit in my case since I can´t use ambient lighting in 2D and use my own light anyway.

    I thought about adding several gameobjects with a 50% transparency and different colors from white to black and make them switch. Kinda works, but there has to be elegant and functional ways to do that. Hollow Knight for example also offers a fully functional brightness slider.

    Anyway. do you guys have any recommendations? Did that for a game yourself? I am happy to discuss the topic. If I´m understanding something fundamentally wrong I´d be glad if you pointed me in the right direction

    Edit: I just realized I am also having trouble with the persistence when changing to different scenes. How did you guys approach that problem?

    Thx and greetz!
     
    Last edited: Apr 12, 2019
  2. beanie4now

    beanie4now

    Joined:
    Apr 22, 2018
    Posts:
    311
    Public static class GameData for persistence.