Ejemplo n.º 1
0
 public void Show(string content, float duration, Action <GerenicToast> onBeginClose, Action <GerenicToast> onClosed)
 {
     mOnBeginClose  = onBeginClose;
     mOnClosed      = onClosed;
     mCheckResize   = 2;
     m_Content.text = content;
     mCdId          = RealTimeTimer.Register(duration, Close);
 }
Ejemplo n.º 2
0
 public Core(AgentBase agent, Dictionary <string, object> attributes)
     : base(agent, new string[] { }, new string[] { })
 {
     // default connection values, use attributes to override
     botName = "POSHbot";
     clients = new Dictionary <string, BWAPI.IStarcraftBot>();
     Timer   = new RealTimeTimer(50L);
     // Create the thread object, passing in the method
     // via a ThreadStart delegate. This does not start the thread.
     oThread    = new Thread(new ThreadStart(this.RunBot));
     bwtaThread = new Thread(new ThreadStart(this.RunBWTA));
 }
Ejemplo n.º 3
0
        public void Close()
        {
            RealTimeTimer.Unregister(mCdId);
            if (mOnBeginClose != null)
            {
                mOnBeginClose(this);
            }
            mOnBeginClose = null;
            float dur = m_ToastCanvas.PlayGroup("out");

            Timer.Register(Mathf.Min(dur, 1), mOnTweenFinish);
        }
Ejemplo n.º 4
0
 public void Start(IUILoader uiLoader, System.Action callback)
 {
     mActive           = true;
     mUILoader         = uiLoader;
     mOnLoadedCallback = callback;
     if (on_start_load_window != null)
     {
         on_start_load_window();
         RealTimeTimer.Register(0.1f, mStartLoad);
     }
     else
     {
         StartLoad();
     }
 }
Ejemplo n.º 5
0
 public EmptyDelayShot(TimeSpan delay)
 {
     delayTimer = new RealTimeTimer(delay);
 }
Ejemplo n.º 6
0
        public AfterShotDelayDecorator(IShot shot, TimeSpan delay)
        {
            this.shot = shot;

            delayTimer = new RealTimeTimer(delay);
        }
Ejemplo n.º 7
0
        public BeforeStartDelayDecorator(IShot shot, TimeSpan delay)
        {
            this.shot = shot;

            delayTimer = new RealTimeTimer(delay);
        }