示例#1
0
    private void Start()
    {
        if (Instance != null)
        {
            realDestroy = false;
            DestroyImmediate(gameObject);
            return;
        }

        this.realDestroy = true;
        this.name        = AppName;
        Instance         = this;
        DontDestroyOnLoad(gameObject);

        Dispatcher    = new Dispatcher();
        SdkTool       = new SdkTool();
        DataColloct   = new DataColloct();
        GamepadServer = new GamepadServer();
        Input         = new LTInput();

        gameObject.AddComponent <AndroidAPIBridge>();
    }
示例#2
0
 private void Update()
 {
     Dispatcher?.Update();
     GamepadServer?.Update();
     Input?.Update();
 }
示例#3
0
 /// <summary>
 /// 初始化服务
 /// </summary>
 public void Init()
 {
     //App.Make<IGamepadServer>();
     server = new GamepadServer(this);
 }