Beispiel #1
0
        private IEnumerator UpdateCor()
        {
            float t = 0.0f;

            while ((t += Time.deltaTime) < time)
            {
                TimeEvent.Invoke(t / time);
                yield return(new WaitForEndOfFrame());
            }
            TimeEvent.Invoke(1.0f);
            yield return(new WaitUntil(() => teleportAction.GetStateUp(SteamVR_Input_Sources.Any)));

            yield return(new WaitUntil(() => teleportAction.GetStateUp(SteamVR_Input_Sources.Any)));

            OnClickEvent.Invoke();
        }
Beispiel #2
0
        public void Remain(float y)
        {
            switch (Net.Status)
            {
            case Corsair.NetStatus.Server:
                NetData n = Manager.CreateNetData(NetID, (byte)NetStatus.Remain);
                n.Write(y);
                NetServer.Send(n);
                RemainEvent.Invoke(y);
                break;

            case Corsair.NetStatus.Client:
                RemainEvent.Invoke(y);
                break;

            case Corsair.NetStatus.Null:
                RemainEvent.Invoke(y);
                break;
            }
        }