diff options
Diffstat (limited to 'core/project_settings.h')
-rw-r--r-- | core/project_settings.h | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/core/project_settings.h b/core/project_settings.h index b01e7855aa..75ebc5acc8 100644 --- a/core/project_settings.h +++ b/core/project_settings.h @@ -59,18 +59,21 @@ protected: Variant initial; bool hide_from_editor; bool overridden; + bool restart_if_changed; VariantContainer() : order(0), persist(false), hide_from_editor(false), - overridden(false) { + overridden(false), + restart_if_changed(false) { } VariantContainer(const Variant &p_variant, int p_order, bool p_persist = false) : order(p_order), persist(p_persist), variant(p_variant), hide_from_editor(false), - overridden(false) { + overridden(false), + restart_if_changed(false) { } }; @@ -120,6 +123,7 @@ public: String globalize_path(const String &p_path) const; void set_initial_value(const String &p_name, const Variant &p_value); + void set_restart_if_changed(const String &p_name, bool p_restart); bool property_can_revert(const String &p_name); Variant property_get_revert(const String &p_name); @@ -137,6 +141,7 @@ public: Error save_custom(const String &p_path = "", const CustomMap &p_custom = CustomMap(), const Vector<String> &p_custom_features = Vector<String>(), bool p_merge_with_current = true); Error save(); void set_custom_property_info(const String &p_prop, const PropertyInfo &p_info); + const Map<StringName, PropertyInfo> &get_custom_property_info() const; Vector<String> get_optimizer_presets() const; @@ -150,13 +155,16 @@ public: void set_registering_order(bool p_enable); + bool has_custom_feature(const String &p_feature) const; + ProjectSettings(); ~ProjectSettings(); }; //not a macro any longer -Variant _GLOBAL_DEF(const String &p_var, const Variant &p_default); +Variant _GLOBAL_DEF(const String &p_var, const Variant &p_default, bool p_restart_if_changed = false); #define GLOBAL_DEF(m_var, m_value) _GLOBAL_DEF(m_var, m_value) +#define GLOBAL_DEF_RST(m_var, m_value) _GLOBAL_DEF(m_var, m_value, true) #define GLOBAL_GET(m_var) ProjectSettings::get_singleton()->get(m_var) #endif |