@@ -212,6 +212,11 @@ namespace Atomic
void IPCPlayerApp::Stop()
{
+ if (debugPlayer_)
+ {
+ context_->GetSubsystem<JSDebugger>()->Shutdown();
+ }
+
PlayerApp::Stop();
}
@@ -27,6 +27,10 @@ JSDebugger::~JSDebugger()
instance_ = NULL;
+void JSDebugger::Shutdown() const
+{
+ instance_ = NULL;
+}
void JSDebugger::Reconnect() const
@@ -45,6 +45,9 @@ public:
/// Reconnect to debugger socket (blocks main thread currently)
void Reconnect() const;
+ /// Shut down the debugger
+ void Shutdown() const;
/// Get the JSDebugger subsystem from external code
static JSDebugger* GetInstance() { return instance_; }