diff options
22 files changed, 46 insertions, 72 deletions
diff --git a/core/io/multiplayer_api.cpp b/core/io/multiplayer_api.cpp index 30b9e1f108..3f66e00021 100644 --- a/core/io/multiplayer_api.cpp +++ b/core/io/multiplayer_api.cpp @@ -1293,9 +1293,7 @@ void MultiplayerAPI::_bind_methods() { BIND_ENUM_CONSTANT(RPC_MODE_REMOTE); BIND_ENUM_CONSTANT(RPC_MODE_MASTER); BIND_ENUM_CONSTANT(RPC_MODE_PUPPET); - BIND_ENUM_CONSTANT(RPC_MODE_SLAVE); // Deprecated. BIND_ENUM_CONSTANT(RPC_MODE_REMOTESYNC); - BIND_ENUM_CONSTANT(RPC_MODE_SYNC); // Deprecated. BIND_ENUM_CONSTANT(RPC_MODE_MASTERSYNC); BIND_ENUM_CONSTANT(RPC_MODE_PUPPETSYNC); } diff --git a/core/io/multiplayer_api.h b/core/io/multiplayer_api.h index 6672cfe155..8748dba03c 100644 --- a/core/io/multiplayer_api.h +++ b/core/io/multiplayer_api.h @@ -135,9 +135,7 @@ public: RPC_MODE_REMOTE, // Using rpc() on it will call method / set property in all remote peers RPC_MODE_MASTER, // Using rpc() on it will call method on wherever the master is, be it local or remote RPC_MODE_PUPPET, // Using rpc() on it will call method for all puppets - RPC_MODE_SLAVE = RPC_MODE_PUPPET, // Deprecated, same as puppet RPC_MODE_REMOTESYNC, // Using rpc() on it will call method / set property in all remote peers and locally - RPC_MODE_SYNC = RPC_MODE_REMOTESYNC, // Deprecated. Same as RPC_MODE_REMOTESYNC RPC_MODE_MASTERSYNC, // Using rpc() on it will call method / set property in the master peer and locally RPC_MODE_PUPPETSYNC, // Using rpc() on it will call method / set property in all puppets peers and locally }; diff --git a/doc/classes/MultiplayerAPI.xml b/doc/classes/MultiplayerAPI.xml index ce62769cf0..b82214b246 100644 --- a/doc/classes/MultiplayerAPI.xml +++ b/doc/classes/MultiplayerAPI.xml @@ -151,15 +151,9 @@ <constant name="RPC_MODE_PUPPET" value="3" enum="RPCMode"> Used with [method Node.rpc_config] or [method Node.rset_config] to set a method to be called or a property to be changed only on puppets for this node. Analogous to the [code]puppet[/code] keyword. Only accepts calls or property changes from the node's network master, see [method Node.set_network_master]. </constant> - <constant name="RPC_MODE_SLAVE" value="3" enum="RPCMode"> - [i]Deprecated.[/i] Use [constant RPC_MODE_PUPPET] instead. Analogous to the [code]slave[/code] keyword. - </constant> <constant name="RPC_MODE_REMOTESYNC" value="4" enum="RPCMode"> Behave like [constant RPC_MODE_REMOTE] but also make the call or property change locally. Analogous to the [code]remotesync[/code] keyword. </constant> - <constant name="RPC_MODE_SYNC" value="4" enum="RPCMode"> - [i]Deprecated.[/i] Use [constant RPC_MODE_REMOTESYNC] instead. Analogous to the [code]sync[/code] keyword. - </constant> <constant name="RPC_MODE_MASTERSYNC" value="5" enum="RPCMode"> Behave like [constant RPC_MODE_MASTER] but also make the call or property change locally. Analogous to the [code]mastersync[/code] keyword. </constant> diff --git a/doc/classes/ProjectSettings.xml b/doc/classes/ProjectSettings.xml index 517c68221e..335fe0aab8 100644 --- a/doc/classes/ProjectSettings.xml +++ b/doc/classes/ProjectSettings.xml @@ -284,7 +284,7 @@ If [code]true[/code], enables warnings when a constant is used as a function. </member> <member name="debug/gdscript/warnings/deprecated_keyword" type="bool" setter="" getter="" default="true"> - If [code]true[/code], enables warnings when deprecated keywords such as [code]slave[/code] are used. + If [code]true[/code], enables warnings when deprecated keywords are used. </member> <member name="debug/gdscript/warnings/enable" type="bool" setter="" getter="" default="true"> If [code]true[/code], enables specific GDScript warnings (see [code]debug/gdscript/warnings/*[/code] settings). If [code]false[/code], disables all GDScript warnings. diff --git a/doc/classes/VisualShaderNodeCustom.xml b/doc/classes/VisualShaderNodeCustom.xml index 9ccdf0d3c4..0d1bcc754f 100644 --- a/doc/classes/VisualShaderNodeCustom.xml +++ b/doc/classes/VisualShaderNodeCustom.xml @@ -143,6 +143,14 @@ Defining this method is [b]optional[/b]. If not overridden, the node will be filed under the root of the main category (see [method _get_category]). </description> </method> + <method name="_is_highend" qualifiers="virtual"> + <return type="bool"> + </return> + <description> + Override this method to enable high-end mark in the Visual Shader Editor's members dialog. + Defining this method is [b]optional[/b]. If not overridden, it's false. + </description> + </method> </methods> <constants> </constants> diff --git a/editor/editor_settings.cpp b/editor/editor_settings.cpp index 715ce6bea7..d81b9bbb82 100644 --- a/editor/editor_settings.cpp +++ b/editor/editor_settings.cpp @@ -628,7 +628,7 @@ void EditorSettings::_load_defaults(Ref<ConfigFile> p_extra_config) { /* Extra config */ _initial_set("project_manager/sorting_order", 0); - hints["project_manager/sorting_order"] = PropertyInfo(Variant::INT, "project_manager/sorting_order", PROPERTY_HINT_ENUM, "Name,Path,Last Modified"); + hints["project_manager/sorting_order"] = PropertyInfo(Variant::INT, "project_manager/sorting_order", PROPERTY_HINT_ENUM, "Name,Path,Last Edited"); if (p_extra_config.is_valid()) { diff --git a/editor/plugins/visual_shader_editor_plugin.cpp b/editor/plugins/visual_shader_editor_plugin.cpp index 438c640bab..ebd7b4edf6 100644 --- a/editor/plugins/visual_shader_editor_plugin.cpp +++ b/editor/plugins/visual_shader_editor_plugin.cpp @@ -116,7 +116,7 @@ void VisualShaderEditor::clear_custom_types() { } } -void VisualShaderEditor::add_custom_type(const String &p_name, const Ref<Script> &p_script, const String &p_description, int p_return_icon_type, const String &p_category, const String &p_subcategory) { +void VisualShaderEditor::add_custom_type(const String &p_name, const Ref<Script> &p_script, const String &p_description, int p_return_icon_type, const String &p_category, const String &p_subcategory, bool p_highend) { ERR_FAIL_COND(!p_name.is_valid_identifier()); ERR_FAIL_COND(!p_script.is_valid()); @@ -135,6 +135,7 @@ void VisualShaderEditor::add_custom_type(const String &p_name, const Ref<Script> ao.description = p_description; ao.category = p_category; ao.sub_category = p_subcategory; + ao.highend = p_highend; ao.is_custom = true; bool begin = false; @@ -247,6 +248,11 @@ void VisualShaderEditor::update_custom_nodes() { subcategory = (String)ref->call("_get_subcategory"); } + bool highend = false; + if (ref->has_method("_is_highend")) { + highend = (bool)ref->call("_is_highend"); + } + Dictionary dict; dict["name"] = name; dict["script"] = script; @@ -254,6 +260,7 @@ void VisualShaderEditor::update_custom_nodes() { dict["return_icon_type"] = return_icon_type; dict["category"] = category; dict["subcategory"] = subcategory; + dict["highend"] = highend; String key; key = category; @@ -277,7 +284,7 @@ void VisualShaderEditor::update_custom_nodes() { const Dictionary &value = (Dictionary)added[key]; - add_custom_type(value["name"], value["script"], value["description"], value["return_icon_type"], value["category"], value["subcategory"]); + add_custom_type(value["name"], value["script"], value["description"], value["return_icon_type"], value["category"], value["subcategory"], value["highend"]); } _update_options_menu(); diff --git a/editor/plugins/visual_shader_editor_plugin.h b/editor/plugins/visual_shader_editor_plugin.h index f4971ae36d..150cf16167 100644 --- a/editor/plugins/visual_shader_editor_plugin.h +++ b/editor/plugins/visual_shader_editor_plugin.h @@ -265,7 +265,7 @@ public: static VisualShaderEditor *get_singleton() { return singleton; } void clear_custom_types(); - void add_custom_type(const String &p_name, const Ref<Script> &p_script, const String &p_description, int p_return_icon_type, const String &p_category, const String &p_subcategory); + void add_custom_type(const String &p_name, const Ref<Script> &p_script, const String &p_description, int p_return_icon_type, const String &p_category, const String &p_subcategory, bool p_highend); virtual Size2 get_minimum_size() const; void edit(VisualShader *p_visual_shader); diff --git a/editor/project_manager.cpp b/editor/project_manager.cpp index a91e14dd1d..d90e76fe39 100644 --- a/editor/project_manager.cpp +++ b/editor/project_manager.cpp @@ -1001,7 +1001,7 @@ public: String path; String icon; String main_scene; - uint64_t last_modified; + uint64_t last_edited; bool favorite; bool grayed; bool missing; @@ -1017,7 +1017,7 @@ public: const String &p_path, const String &p_icon, const String &p_main_scene, - uint64_t p_last_modified, + uint64_t p_last_edited, bool p_favorite, bool p_grayed, bool p_missing, @@ -1029,7 +1029,7 @@ public: path = p_path; icon = p_icon; main_scene = p_main_scene; - last_modified = p_last_modified; + last_edited = p_last_edited; favorite = p_favorite; grayed = p_grayed; missing = p_missing; @@ -1104,8 +1104,8 @@ struct ProjectListComparator { switch (order_option) { case ProjectListFilter::FILTER_PATH: return a.project_key < b.project_key; - case ProjectListFilter::FILTER_MODIFIED: - return a.last_modified > b.last_modified; + case ProjectListFilter::FILTER_EDIT_DATE: + return a.last_edited > b.last_edited; default: return a.project_name < b.project_name; } @@ -1113,7 +1113,7 @@ struct ProjectListComparator { }; ProjectList::ProjectList() { - _order_option = ProjectListFilter::FILTER_MODIFIED; + _order_option = ProjectListFilter::FILTER_EDIT_DATE; _scroll_children = memnew(VBoxContainer); _scroll_children->set_h_size_flags(SIZE_EXPAND_FILL); @@ -1200,15 +1200,18 @@ void ProjectList::load_project_data(const String &p_property_key, Item &p_item, String icon = cf->get_value("application", "config/icon", ""); String main_scene = cf->get_value("application", "run/main_scene", ""); - uint64_t last_modified = 0; + uint64_t last_edited = 0; if (FileAccess::exists(conf)) { - last_modified = FileAccess::get_modified_time(conf); + // The modification date marks the date the project was last edited. + // This is because the `project.godot` file will always be modified + // when editing a project (but not when running it). + last_edited = FileAccess::get_modified_time(conf); String fscache = path.plus_file(".fscache"); if (FileAccess::exists(fscache)) { uint64_t cache_modified = FileAccess::get_modified_time(fscache); - if (cache_modified > last_modified) - last_modified = cache_modified; + if (cache_modified > last_edited) + last_edited = cache_modified; } } else { grayed = true; @@ -1218,7 +1221,7 @@ void ProjectList::load_project_data(const String &p_property_key, Item &p_item, String project_key = p_property_key.get_slice("/", 1); - p_item = Item(project_key, project_name, description, path, icon, main_scene, last_modified, p_favorite, grayed, missing, config_version); + p_item = Item(project_key, project_name, description, path, icon, main_scene, last_edited, p_favorite, grayed, missing, config_version); } void ProjectList::load_projects() { @@ -2515,7 +2518,7 @@ ProjectManager::ProjectManager() { Vector<String> sort_filter_titles; sort_filter_titles.push_back(TTR("Name")); sort_filter_titles.push_back(TTR("Path")); - sort_filter_titles.push_back(TTR("Last Modified")); + sort_filter_titles.push_back(TTR("Last Edited")); project_order_filter = memnew(ProjectListFilter); project_order_filter->add_filter_option(); project_order_filter->_setup_filters(sort_filter_titles); diff --git a/editor/project_manager.h b/editor/project_manager.h index b8f7403e27..feeea9695d 100644 --- a/editor/project_manager.h +++ b/editor/project_manager.h @@ -134,7 +134,7 @@ public: enum FilterOption { FILTER_NAME, FILTER_PATH, - FILTER_MODIFIED, + FILTER_EDIT_DATE, }; private: diff --git a/modules/gdnative/include/nativescript/godot_nativescript.h b/modules/gdnative/include/nativescript/godot_nativescript.h index d2ed4fb3e5..1b131c8cf0 100644 --- a/modules/gdnative/include/nativescript/godot_nativescript.h +++ b/modules/gdnative/include/nativescript/godot_nativescript.h @@ -42,9 +42,7 @@ typedef enum { GODOT_METHOD_RPC_MODE_REMOTE, GODOT_METHOD_RPC_MODE_MASTER, GODOT_METHOD_RPC_MODE_PUPPET, - GODOT_METHOD_RPC_MODE_SLAVE = GODOT_METHOD_RPC_MODE_PUPPET, GODOT_METHOD_RPC_MODE_REMOTESYNC, - GODOT_METHOD_RPC_MODE_SYNC = GODOT_METHOD_RPC_MODE_REMOTESYNC, GODOT_METHOD_RPC_MODE_MASTERSYNC, GODOT_METHOD_RPC_MODE_PUPPETSYNC, } godot_method_rpc_mode; diff --git a/modules/gdscript/gdscript.cpp b/modules/gdscript/gdscript.cpp index e4da60b5b9..c71ec6ec76 100644 --- a/modules/gdscript/gdscript.cpp +++ b/modules/gdscript/gdscript.cpp @@ -1957,10 +1957,8 @@ void GDScriptLanguage::get_reserved_words(List<String> *p_words) const { "match", "while", "remote", - "sync", "master", "puppet", - "slave", "remotesync", "mastersync", "puppetsync", diff --git a/modules/gdscript/gdscript_editor.cpp b/modules/gdscript/gdscript_editor.cpp index 65c61cb57c..c2c8ff5b99 100644 --- a/modules/gdscript/gdscript_editor.cpp +++ b/modules/gdscript/gdscript_editor.cpp @@ -2186,7 +2186,7 @@ static void _find_identifiers(const GDScriptCompletionContext &p_context, bool p "and", "in", "not", "or", "false", "PI", "TAU", "INF", "NAN", "self", "true", "as", "assert", "breakpoint", "class", "extends", "is", "func", "preload", "setget", "signal", "tool", "yield", "const", "enum", "export", "onready", "static", "var", "break", "continue", "if", "elif", - "else", "for", "pass", "return", "match", "while", "remote", "sync", "master", "puppet", "slave", + "else", "for", "pass", "return", "match", "while", "remote", "master", "puppet", "remotesync", "mastersync", "puppetsync", 0 }; diff --git a/modules/gdscript/gdscript_parser.cpp b/modules/gdscript/gdscript_parser.cpp index d125da5b79..84ac13f45e 100644 --- a/modules/gdscript/gdscript_parser.cpp +++ b/modules/gdscript/gdscript_parser.cpp @@ -4588,10 +4588,10 @@ void GDScriptParser::_parse_class(ClassNode *p_class) { #undef _ADVANCE_AND_CONSUME_NEWLINES } - if (tokenizer->get_token() != GDScriptTokenizer::TK_PR_VAR && tokenizer->get_token() != GDScriptTokenizer::TK_PR_ONREADY && tokenizer->get_token() != GDScriptTokenizer::TK_PR_REMOTE && tokenizer->get_token() != GDScriptTokenizer::TK_PR_MASTER && tokenizer->get_token() != GDScriptTokenizer::TK_PR_PUPPET && tokenizer->get_token() != GDScriptTokenizer::TK_PR_SYNC && tokenizer->get_token() != GDScriptTokenizer::TK_PR_REMOTESYNC && tokenizer->get_token() != GDScriptTokenizer::TK_PR_MASTERSYNC && tokenizer->get_token() != GDScriptTokenizer::TK_PR_PUPPETSYNC && tokenizer->get_token() != GDScriptTokenizer::TK_PR_SLAVE) { + if (tokenizer->get_token() != GDScriptTokenizer::TK_PR_VAR && tokenizer->get_token() != GDScriptTokenizer::TK_PR_ONREADY && tokenizer->get_token() != GDScriptTokenizer::TK_PR_REMOTE && tokenizer->get_token() != GDScriptTokenizer::TK_PR_MASTER && tokenizer->get_token() != GDScriptTokenizer::TK_PR_PUPPET && tokenizer->get_token() != GDScriptTokenizer::TK_PR_REMOTESYNC && tokenizer->get_token() != GDScriptTokenizer::TK_PR_MASTERSYNC && tokenizer->get_token() != GDScriptTokenizer::TK_PR_PUPPETSYNC) { current_export = PropertyInfo(); - _set_error("Expected \"var\", \"onready\", \"remote\", \"master\", \"puppet\", \"sync\", \"remotesync\", \"mastersync\", \"puppetsync\"."); + _set_error("Expected \"var\", \"onready\", \"remote\", \"master\", \"puppet\", \"remotesync\", \"mastersync\", \"puppetsync\"."); return; } @@ -4648,11 +4648,6 @@ void GDScriptParser::_parse_class(ClassNode *p_class) { rpc_mode = MultiplayerAPI::RPC_MODE_MASTER; continue; } break; - case GDScriptTokenizer::TK_PR_SLAVE: -#ifdef DEBUG_ENABLED - _add_warning(GDScriptWarning::DEPRECATED_KEYWORD, tokenizer->get_token_line(), "slave", "puppet"); -#endif - FALLTHROUGH; case GDScriptTokenizer::TK_PR_PUPPET: { //may be fallthrough from export, ignore if so @@ -4673,8 +4668,7 @@ void GDScriptParser::_parse_class(ClassNode *p_class) { rpc_mode = MultiplayerAPI::RPC_MODE_PUPPET; continue; } break; - case GDScriptTokenizer::TK_PR_REMOTESYNC: - case GDScriptTokenizer::TK_PR_SYNC: { + case GDScriptTokenizer::TK_PR_REMOTESYNC: { //may be fallthrough from export, ignore if so tokenizer->advance(); diff --git a/modules/gdscript/gdscript_tokenizer.cpp b/modules/gdscript/gdscript_tokenizer.cpp index 11ffa22906..8e28b7215b 100644 --- a/modules/gdscript/gdscript_tokenizer.cpp +++ b/modules/gdscript/gdscript_tokenizer.cpp @@ -106,11 +106,9 @@ const char *GDScriptTokenizer::token_names[TK_MAX] = { "yield", "signal", "breakpoint", - "rpc", - "sync", + "remote", "master", "puppet", - "slave", "remotesync", "mastersync", "puppetsync", @@ -207,9 +205,7 @@ static const _kws _keyword_list[] = { { GDScriptTokenizer::TK_PR_BREAKPOINT, "breakpoint" }, { GDScriptTokenizer::TK_PR_REMOTE, "remote" }, { GDScriptTokenizer::TK_PR_MASTER, "master" }, - { GDScriptTokenizer::TK_PR_SLAVE, "slave" }, { GDScriptTokenizer::TK_PR_PUPPET, "puppet" }, - { GDScriptTokenizer::TK_PR_SYNC, "sync" }, { GDScriptTokenizer::TK_PR_REMOTESYNC, "remotesync" }, { GDScriptTokenizer::TK_PR_MASTERSYNC, "mastersync" }, { GDScriptTokenizer::TK_PR_PUPPETSYNC, "puppetsync" }, @@ -255,7 +251,6 @@ bool GDScriptTokenizer::is_token_literal(int p_offset, bool variable_safe) const case TK_PR_REMOTE: case TK_PR_MASTER: case TK_PR_PUPPET: - case TK_PR_SYNC: case TK_PR_REMOTESYNC: case TK_PR_MASTERSYNC: case TK_PR_PUPPETSYNC: diff --git a/modules/gdscript/gdscript_tokenizer.h b/modules/gdscript/gdscript_tokenizer.h index 0efc8551cb..3694825d80 100644 --- a/modules/gdscript/gdscript_tokenizer.h +++ b/modules/gdscript/gdscript_tokenizer.h @@ -113,9 +113,7 @@ public: TK_PR_SIGNAL, TK_PR_BREAKPOINT, TK_PR_REMOTE, - TK_PR_SYNC, TK_PR_MASTER, - TK_PR_SLAVE, // Deprecated by TK_PR_PUPPET, to remove in 4.0 TK_PR_PUPPET, TK_PR_REMOTESYNC, TK_PR_MASTERSYNC, diff --git a/modules/mono/csharp_script.cpp b/modules/mono/csharp_script.cpp index 10bc3dcb49..43cdd19411 100644 --- a/modules/mono/csharp_script.cpp +++ b/modules/mono/csharp_script.cpp @@ -3373,12 +3373,8 @@ MultiplayerAPI::RPCMode CSharpScript::_member_get_rpc_mode(IMonoClassMember *p_m return MultiplayerAPI::RPC_MODE_MASTER; if (p_member->has_attribute(CACHED_CLASS(PuppetAttribute))) return MultiplayerAPI::RPC_MODE_PUPPET; - if (p_member->has_attribute(CACHED_CLASS(SlaveAttribute))) - return MultiplayerAPI::RPC_MODE_PUPPET; if (p_member->has_attribute(CACHED_CLASS(RemoteSyncAttribute))) return MultiplayerAPI::RPC_MODE_REMOTESYNC; - if (p_member->has_attribute(CACHED_CLASS(SyncAttribute))) - return MultiplayerAPI::RPC_MODE_REMOTESYNC; if (p_member->has_attribute(CACHED_CLASS(MasterSyncAttribute))) return MultiplayerAPI::RPC_MODE_MASTERSYNC; if (p_member->has_attribute(CACHED_CLASS(PuppetSyncAttribute))) diff --git a/modules/mono/glue/GodotSharp/GodotSharp/Core/Attributes/RPCAttributes.cs b/modules/mono/glue/GodotSharp/GodotSharp/Core/Attributes/RPCAttributes.cs index 1bf6d5199a..8fc430b6bc 100644 --- a/modules/mono/glue/GodotSharp/GodotSharp/Core/Attributes/RPCAttributes.cs +++ b/modules/mono/glue/GodotSharp/GodotSharp/Core/Attributes/RPCAttributes.cs @@ -6,18 +6,12 @@ namespace Godot public class RemoteAttribute : Attribute {} [AttributeUsage(AttributeTargets.Method | AttributeTargets.Field | AttributeTargets.Property)] - public class SyncAttribute : Attribute {} - - [AttributeUsage(AttributeTargets.Method | AttributeTargets.Field | AttributeTargets.Property)] public class MasterAttribute : Attribute {} [AttributeUsage(AttributeTargets.Method | AttributeTargets.Field | AttributeTargets.Property)] public class PuppetAttribute : Attribute {} [AttributeUsage(AttributeTargets.Method | AttributeTargets.Field | AttributeTargets.Property)] - public class SlaveAttribute : Attribute {} - - [AttributeUsage(AttributeTargets.Method | AttributeTargets.Field | AttributeTargets.Property)] public class RemoteSyncAttribute : Attribute {} [AttributeUsage(AttributeTargets.Method | AttributeTargets.Field | AttributeTargets.Property)] diff --git a/modules/mono/mono_gd/gd_mono_cache.cpp b/modules/mono/mono_gd/gd_mono_cache.cpp index f1f6524cd2..0ad90a510e 100644 --- a/modules/mono/mono_gd/gd_mono_cache.cpp +++ b/modules/mono/mono_gd/gd_mono_cache.cpp @@ -136,10 +136,8 @@ void CachedData::clear_godot_api_cache() { class_SignalAttribute = NULL; class_ToolAttribute = NULL; class_RemoteAttribute = NULL; - class_SyncAttribute = NULL; class_MasterAttribute = NULL; class_PuppetAttribute = NULL; - class_SlaveAttribute = NULL; class_RemoteSyncAttribute = NULL; class_MasterSyncAttribute = NULL; class_PuppetSyncAttribute = NULL; @@ -254,10 +252,8 @@ void update_godot_api_cache() { CACHE_CLASS_AND_CHECK(SignalAttribute, GODOT_API_CLASS(SignalAttribute)); CACHE_CLASS_AND_CHECK(ToolAttribute, GODOT_API_CLASS(ToolAttribute)); CACHE_CLASS_AND_CHECK(RemoteAttribute, GODOT_API_CLASS(RemoteAttribute)); - CACHE_CLASS_AND_CHECK(SyncAttribute, GODOT_API_CLASS(SyncAttribute)); CACHE_CLASS_AND_CHECK(MasterAttribute, GODOT_API_CLASS(MasterAttribute)); CACHE_CLASS_AND_CHECK(PuppetAttribute, GODOT_API_CLASS(PuppetAttribute)); - CACHE_CLASS_AND_CHECK(SlaveAttribute, GODOT_API_CLASS(SlaveAttribute)); CACHE_CLASS_AND_CHECK(RemoteSyncAttribute, GODOT_API_CLASS(RemoteSyncAttribute)); CACHE_CLASS_AND_CHECK(MasterSyncAttribute, GODOT_API_CLASS(MasterSyncAttribute)); CACHE_CLASS_AND_CHECK(PuppetSyncAttribute, GODOT_API_CLASS(PuppetSyncAttribute)); diff --git a/modules/mono/mono_gd/gd_mono_cache.h b/modules/mono/mono_gd/gd_mono_cache.h index 1dc6b70479..0458e91240 100644 --- a/modules/mono/mono_gd/gd_mono_cache.h +++ b/modules/mono/mono_gd/gd_mono_cache.h @@ -106,13 +106,11 @@ struct CachedData { GDMonoClass *class_SignalAttribute; GDMonoClass *class_ToolAttribute; GDMonoClass *class_RemoteAttribute; - GDMonoClass *class_SyncAttribute; + GDMonoClass *class_MasterAttribute; + GDMonoClass *class_PuppetAttribute; GDMonoClass *class_RemoteSyncAttribute; GDMonoClass *class_MasterSyncAttribute; GDMonoClass *class_PuppetSyncAttribute; - GDMonoClass *class_MasterAttribute; - GDMonoClass *class_PuppetAttribute; - GDMonoClass *class_SlaveAttribute; GDMonoClass *class_GodotMethodAttribute; GDMonoField *field_GodotMethodAttribute_methodName; diff --git a/platform/javascript/engine.js b/platform/javascript/engine.js index 1f78aa672d..227accadb0 100644 --- a/platform/javascript/engine.js +++ b/platform/javascript/engine.js @@ -134,12 +134,10 @@ this.startGame = function(execName, mainPack) { executableName = execName; - var mainArgs = [ '--main-pack', mainPack ]; + var mainArgs = [ '--main-pack', getPathLeaf(mainPack) ]; return Promise.all([ - // Load from directory, - this.init(getBasePath(mainPack)), - // ...but write to root where the engine expects it. + this.init(getBasePath(execName)), this.preloadFile(mainPack, getPathLeaf(mainPack)) ]).then( Function.prototype.apply.bind(synchronousStart, this, mainArgs) diff --git a/scene/resources/visual_shader.cpp b/scene/resources/visual_shader.cpp index b3a72ea7b6..f80fe9f791 100644 --- a/scene/resources/visual_shader.cpp +++ b/scene/resources/visual_shader.cpp @@ -276,6 +276,7 @@ void VisualShaderNodeCustom::_bind_methods() { BIND_VMETHOD(MethodInfo(Variant::STRING, "_get_output_port_name", PropertyInfo(Variant::INT, "port"))); BIND_VMETHOD(MethodInfo(Variant::STRING, "_get_code", PropertyInfo(Variant::ARRAY, "input_vars"), PropertyInfo(Variant::ARRAY, "output_vars"), PropertyInfo(Variant::INT, "mode"), PropertyInfo(Variant::INT, "type"))); BIND_VMETHOD(MethodInfo(Variant::STRING, "_get_global_code", PropertyInfo(Variant::INT, "mode"))); + BIND_VMETHOD(MethodInfo(Variant::BOOL, "_is_highend")); } VisualShaderNodeCustom::VisualShaderNodeCustom() { |