Allow PluginScript to customize language's can_inherit_from_file attribute

This commit is contained in:
Emmanuel Leblond 2020-12-08 00:56:01 +01:00
parent efc2104096
commit 014efeb272
No known key found for this signature in database
GPG key ID: C360860E645EFFC0
3 changed files with 6 additions and 1 deletions

View file

@ -142,6 +142,10 @@ bool PluginScriptLanguage::supports_builtin_mode() const {
return _desc.supports_builtin_mode;
}
bool PluginScriptLanguage::can_inherit_from_file() {
return _desc.can_inherit_from_file;
}
int PluginScriptLanguage::find_function(const String &p_function, const String &p_code) const {
if (_desc.find_function) {
return _desc.find_function(_data, (godot_string *)&p_function, (godot_string *)&p_code);