BsScriptCodeImportOptions.h 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. //********************************** Banshee Engine (www.banshee3d.com) **************************************************//
  2. //**************** Copyright (c) 2016 Marko Pintera ([email protected]). All rights reserved. **********************//
  3. #pragma once
  4. #include "BsPrerequisites.h"
  5. #include "BsImportOptions.h"
  6. #include "BsScriptCode.h"
  7. namespace bs
  8. {
  9. /** @addtogroup Resources-Engine
  10. * @{
  11. */
  12. /** Contains import options you may use to control how is a file containing script source code importer. */
  13. class BS_EXPORT ScriptCodeImportOptions : public ImportOptions
  14. {
  15. public:
  16. ScriptCodeImportOptions();
  17. /** Sets whether the script is editor-only or a normal game script. */
  18. void setEditorScript(bool editorScript) { mEditorScript = editorScript; }
  19. /** Checks whether the script is editor-only or a normal game script. */
  20. bool isEditorScript() const { return mEditorScript; }
  21. /** Creates a new import options object that allows you to customize how is script code imported. */
  22. static SPtr<ScriptCodeImportOptions> create();
  23. /************************************************************************/
  24. /* SERIALIZATION */
  25. /************************************************************************/
  26. public:
  27. friend class ScriptCodeImportOptionsRTTI;
  28. static RTTITypeBase* getRTTIStatic();
  29. RTTITypeBase* getRTTI() const override;
  30. private:
  31. bool mEditorScript;
  32. };
  33. /** @} */
  34. }