Mirror of Svelto.ECS because we're a fan of it
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
652B

  1. using UnityEditor;
  2. //This profiler is based on the Entitas Visual Debugging tool
  3. //https://github.com/sschmid/Entitas-CSharp
  4. namespace Svelto.ECS.Profiler
  5. {
  6. internal class EngineProfilerMenuItem
  7. {
  8. [MenuItem("Engines/Enable Profiler")]
  9. public static void EnableProfiler()
  10. {
  11. PlayerSettings.SetScriptingDefineSymbolsForGroup(BuildTargetGroup.Standalone, "ENGINE_PROFILER_ENABLED");
  12. }
  13. [MenuItem("Engines/Disable Profiler")]
  14. public static void DisableProfiler()
  15. {
  16. PlayerSettings.SetScriptingDefineSymbolsForGroup(BuildTargetGroup.Standalone, "");
  17. }
  18. }
  19. }