File tree Expand file tree Collapse file tree 1 file changed +22
-5
lines changed Expand file tree Collapse file tree 1 file changed +22
-5
lines changed Original file line number Diff line number Diff line change @@ -299,6 +299,10 @@ public static void InitExt()
299
299
#endif
300
300
}
301
301
302
+
303
+ public delegate void ShutdownDelegate ( ) ;
304
+ public static ShutdownDelegate ShutdownHandler ;
305
+
302
306
/// <summary>
303
307
/// Shutdown Method
304
308
/// </summary>
@@ -311,13 +315,21 @@ public static void Shutdown()
311
315
{
312
316
if ( initialized )
313
317
{
318
+ ShutdownHandler ( ) ;
319
+
314
320
//////////////////dltrace/////////////////////
315
- /* Exec(@"
316
- import UnityEngine
317
- import threading
318
- UnityEngine.Debug.Log('>>>>>>>>> In PythonEngine.Shutdown() threading.current_thread() = %s'%threading.current_thread())
321
+ /*
322
+ Exec(@"
323
+ import sys
324
+ server_path = 'D:/GoogleDrive/ImgSpc/ut/Uni-67748 Brainstorm ideas SG integration, artist can use SG 247/rpyc/pollingServer'
325
+
326
+ if server_path not in sys.path:
327
+ sys.path.append(server_path)
328
+
329
+ import pollingServer_unity
330
+ pollingServer_unity.stop()
319
331
");
320
- */
332
+ */
321
333
//////////////////dltrace/////////////////////
322
334
323
335
//////////////////dltrace/////////////////////
@@ -375,6 +387,11 @@ import UnityEngine
375
387
Marshal . FreeHGlobal ( _pythonPath ) ;
376
388
_pythonPath = IntPtr . Zero ;
377
389
390
+ Exec ( @"
391
+ import UnityEngine
392
+ UnityEngine.Debug.Log('Python.NET is finalizing the runtime')
393
+ " ) ;
394
+
378
395
Runtime . Shutdown ( ) ;
379
396
380
397
You can’t perform that action at this time.
0 commit comments