示例#1
0
        public override void Intro(IntroCutscene.CoBegin__d Cutscene)
        {
            base.Intro(Cutscene);

            InvisibleCooldown.UpdateForIntro(Cutscene);
            DisguiseCooldown.UpdateForIntro(Cutscene);
        }
示例#2
0
        public override void DoAction(ActionType Type, bool Dead, ref bool Acted)
        {
            if (Dead || !IsLocalPlayer())
            {
                return;
            }

            if (Type == ActionType.PRIMARY)
            {
                if (!InvisibleCooldown.IsReady())
                {
                    return;
                }

                ExtraNetwork.Send(CustomRPC.SpyEffect);
                EnableInvisibility();
                Acted = true;
            }
            else if (Type == ActionType.SIDE)
            {
                if (!DisguiseCooldown.IsReady())
                {
                    return;
                }

                var Players        = PlayerControl.AllPlayerControls;
                var Random         = new System.Random();
                var RandomPlayerId = Players[Random.Next(0, Players.Count)].PlayerId;

                Disguise(RandomPlayerId);
                DisguiseCooldown.Use();
                Acted = true;
            }
        }
示例#3
0
        public override void MeetingEnd(ExileController Exile)
        {
            base.MeetingEnd(Exile);

            IsActive = false;
            InvisibleCooldown.UpdateForExile(Exile);
            DisguiseCooldown.UpdateForExile(Exile);
        }
示例#4
0
        public void EnableInvisibility()
        {
            var Aura = Object.Instantiate(ExtraResources.INVISIBLE_PREFAB,
                                          Player.transform);

            Object.Destroy(Aura, Aura.GetComponent <Animator>()
                           .GetCurrentAnimatorStateInfo(0).length);


            InvisibleCooldown.Use();
            IsActive = true;
        }
示例#5
0
 protected override void ResetRuntime()
 {
     InvisibleCooldown.Reset();
     InvisibleEffect.Reset();
     DisguiseCooldown.Reset();
 }