title: Can I use pre processor directives in Unity to differentiate debug and release mode
body: <p>I want to create a level-based game with Unity. Let's assume you unlock the next level after finishing the previous one. Maybe some levels are locked until you find some items.</p>
  
  <p>How would you test specific parts of your game? Let's say world 3 level 8 contains a part with a cave where the player has to jump over multiple obstacles. How would you test this cave scenario over and over again without restarting the level? I don't mean testing your application with Unit tests. Maybe you want to try out a specific mechanic and a specific spot in a specific level fits best for your tests.</p>
  
  <p>Of course, you could prepare a save game or add some cheat code like "press + to skip this level" but I think the cheat code would be the worst idea because you would have to remove all these lines before releasing your game (and on each next release).</p>
  
  <p>When developing with C# and Visual Studio it's possible to add <a href="https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/preprocessor-directives/preprocessor-if" rel="nofollow noreferrer">preprocessor-directives</a>. Does something similar exist for game development, especially for Unity?</p>