1
0
mirror of https://github.com/godotengine/godot.git synced 2025-12-04 17:04:49 +00:00

Mono: Add assembly reloading to running games

Add environment variable to specify a custom --debugger-agent for mono.
This commit is contained in:
Ignacio Etcheverry
2019-01-21 22:44:05 +01:00
parent 6fa632b821
commit 077e489773
3 changed files with 19 additions and 27 deletions

View File

@@ -30,6 +30,9 @@
#include "mono_bottom_panel.h"
#include "editor/plugins/script_editor_plugin.h"
#include "editor/script_editor_debugger.h"
#include "../csharp_script.h"
#include "../godotsharp_dirs.h"
#include "csharp_project.h"
@@ -160,7 +163,12 @@ void MonoBottomPanel::_build_project_pressed() {
bool build_success = GodotSharpBuilds::get_singleton()->build_project_blocking("Tools");
if (build_success) {
// Notify running game for hot-reload
ScriptEditor::get_singleton()->get_debugger()->reload_scripts();
// Hot-reload in the editor
MonoReloadNode::get_singleton()->restart_reload_timer();
if (CSharpLanguage::get_singleton()->is_assembly_reloading_needed()) {
CSharpLanguage::get_singleton()->reload_assemblies(false);
}