123456789101112131415161718192021222324252627282930313233343536373839404142 |
- using System;
- using System.Collections;
- using System.Collections.Generic;
- using System.Threading;
- using UnityEngine;
- public class TestLock : MonoBehaviour
- {
- ThreadStart threadStart;
- Thread childThread;
- private void Start()
- {;
- threadStart = new ThreadStart(TestThread);
- // ScenceMain.Instance.AddThead(ThreadTest1, null);
- childThread = new Thread(threadStart);
- childThread.Start();
- }
- private void TestThread()
- {
- while(true)
- {
- Thread.Sleep(1000);
- Debug.Log("2222222222222222222");
- }
- }
- public void lockApp()
- {
- //UnityToJava.SetLock();
- }
- public void UnLock()
- {
- // UnityToJava.UnLock();
- }
- private void Update()
- {
- }
- }
|