Changed reload logic to auto-hard-reload scripts on save. It's simpler to use and also fixes #4756

This commit is contained in:
Juan Linietsky 2016-06-13 10:58:32 -03:00
parent 910151a361
commit 45443a1651
5 changed files with 29 additions and 4 deletions

View file

@ -32,7 +32,7 @@ ScriptLanguage *ScriptServer::_languages[MAX_LANGUAGES];
int ScriptServer::_language_count=0;
bool ScriptServer::scripting_enabled=true;
bool ScriptServer::reload_scripts_on_save=false;
void Script::_notification( int p_what) {
@ -92,6 +92,16 @@ void ScriptServer::init_languages() {
}
}
void ScriptServer::set_reload_scripts_on_save(bool p_enable) {
reload_scripts_on_save=p_enable;
}
bool ScriptServer::is_reload_scripts_on_save_enabled() {
return reload_scripts_on_save;
}
void ScriptInstance::get_property_state(List<Pair<StringName, Variant> > &state) {
List<PropertyInfo> pinfo;