Implement the ability to disable classes
* This PR adds the ability to disable classes when building. * For now it's only possible to do this via command like: `scons disable_classes=RayCast2D,Area3D` * Eventually, a proper UI will be implemented to create a build config file to do this at large scale, as well as detect what is used in the project.
This commit is contained in:
parent
fc00a83901
commit
5ad4f26659
44 changed files with 789 additions and 757 deletions
|
|
@ -45,7 +45,7 @@ Ref<ResourceFormatSaverNativeScript> resource_saver_gdns;
|
|||
void register_nativescript_types() {
|
||||
native_script_language = memnew(NativeScriptLanguage);
|
||||
|
||||
ClassDB::register_class<NativeScript>();
|
||||
GDREGISTER_CLASS(NativeScript);
|
||||
|
||||
native_script_language->set_language_index(ScriptServer::get_language_count());
|
||||
ScriptServer::register_language(native_script_language);
|
||||
|
|
|
|||
|
|
@ -34,9 +34,9 @@
|
|||
#include "stream_peer_gdnative.h"
|
||||
|
||||
void register_net_types() {
|
||||
ClassDB::register_class<MultiplayerPeerGDNative>();
|
||||
ClassDB::register_class<PacketPeerGDNative>();
|
||||
ClassDB::register_class<StreamPeerGDNative>();
|
||||
GDREGISTER_CLASS(MultiplayerPeerGDNative);
|
||||
GDREGISTER_CLASS(PacketPeerGDNative);
|
||||
GDREGISTER_CLASS(StreamPeerGDNative);
|
||||
}
|
||||
|
||||
void unregister_net_types() {
|
||||
|
|
|
|||
|
|
@ -107,7 +107,7 @@ void GDAPI godot_pluginscript_register_language(const godot_pluginscript_languag
|
|||
}
|
||||
|
||||
void register_pluginscript_types() {
|
||||
ClassDB::register_class<PluginScript>();
|
||||
GDREGISTER_CLASS(PluginScript);
|
||||
}
|
||||
|
||||
void unregister_pluginscript_types() {
|
||||
|
|
|
|||
|
|
@ -259,8 +259,8 @@ void register_gdnative_types() {
|
|||
EditorNode::add_init_callback(editor_init_callback);
|
||||
#endif
|
||||
|
||||
ClassDB::register_class<GDNativeLibrary>();
|
||||
ClassDB::register_class<GDNative>();
|
||||
GDREGISTER_CLASS(GDNativeLibrary);
|
||||
GDREGISTER_CLASS(GDNative);
|
||||
|
||||
resource_loader_gdnlib.instantiate();
|
||||
ResourceLoader::add_resource_format_loader(resource_loader_gdnlib);
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ void register_videodecoder_types() {
|
|||
resource_loader_vsgdnative.instantiate();
|
||||
ResourceLoader::add_resource_format_loader(resource_loader_vsgdnative, true);
|
||||
|
||||
ClassDB::register_class<VideoStreamGDNative>();
|
||||
GDREGISTER_CLASS(VideoStreamGDNative);
|
||||
}
|
||||
|
||||
void unregister_videodecoder_types() {
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@
|
|||
#include "xr_interface_gdnative.h"
|
||||
|
||||
void register_xr_types() {
|
||||
ClassDB::register_class<XRInterfaceGDNative>();
|
||||
GDREGISTER_CLASS(XRInterfaceGDNative);
|
||||
ClassDB::add_compatibility_class("ARVRInterfaceGDNative", "XRInterfaceGDNative");
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue