Search Unity

Bug HDRP Null reference exception when building game

Discussion in 'Editor & General Support' started by GasterWS, Jan 28, 2023.

  1. GasterWS

    GasterWS

    Joined:
    Aug 28, 2019
    Posts:
    1
    Trying to make a build of my game but get this error, the project is using both HDRP and URP so i can hotswap between them, i can successfully build the project if i remove the URP quality level in Project Settings > Quality.
    but whenever i add the URP quality level and build with it i get this error
    upload_2023-1-28_16-13-31.png
    Pressing the error takes me here (HDRPPreprocessShaders.cs):
    upload_2023-1-28_16-13-21.png

    Anyone knows the reason for this and a potential fix?
     
  2. Kurt-Dekker

    Kurt-Dekker

    Joined:
    Mar 16, 2013
    Posts:
    38,689
    Try a fresh project with both of those features installed and nothing else, see if it builds.

    If it does not build, file a bug with Unity from the Help -> Report a bug menu entry

    If it does work then start bisecting between the empty blank project and your complete project until you find the problem.

    https://en.wikipedia.org/wiki/Bisection_(software_engineering)