コード例 #1
0
    // Specal Skill이 작동하는 함수.
    IEnumerator C_Special_Skill()
    {
        // Target이 죽었을시 새로운 Target을 받는다.
        if (Target.Check_Dead())
        {
            MonsterManager.Get_Inctance().Set_ReTarget(this);
        }

        //현재 Player의 회전값을 저장한후 회전값을 초기화한다.
        Quaternion InitRotation = gameObject.transform.rotation;

        transform.rotation = Quaternion.identity;

        // ActionCamera에게 Wizard의 애니메이션을 실행시키게 한다.
        ActionCamera_Action.Get_Inctance().Set_preparation(transform, "Pirate");

        // Pirate을 제외한 모든 Player, Monster의 Active를 false시킨다.
        PlayerManager.Get_Inctance().Players_Active(gameObject, "OFF");
        MonsterManager.Get_Inctance().Monsters_Active(null, "OFF");

        yield return(new WaitForSeconds(0.25f));

        ani.SetTrigger("SpecialSkill");

        //  NPC들을 활성화시킨후 공격준비를 한다.
        for (int i = 0; i < SpecialSkill_NPC.Length; i++)
        {
            SpecialSkill_NPC[i].SetActive(true);

            yield return(new WaitForSeconds(0.2f));

            SpecialSkill_NPC[i].GetComponent <Henchman_Action>().Start_Attack();
        }

        yield return(new WaitForSeconds(1f));

        ani.SetTrigger("Idle");

        // ActionCamera의 Camera를 끈다.
        ActionCamera_Action.Get_Inctance().CameraOff();

        // Player을 제외한 모든 Player, Monster의 Active를 true시킨다.
        PlayerManager.Get_Inctance().Players_Active(null, "ON");
        MonsterManager.Get_Inctance().Monsters_Active(null, "ON");

        // Player의 회전값을 원래대로 되돌린다.
        transform.rotation = InitRotation;

        // Player들을 Attack상태로 바꾼다. ( Active 변환 때문.)
        PlayerManager.Get_Inctance().Set_Attack();
        MonsterManager.Get_Inctance().Set_ReAttack();

        // SkillPoint를 초기화한다.
        SkillPoint = 0f;
        yield break;
    }
コード例 #2
0
    // Specal Skill이 작동하는 함수.
    IEnumerator C_Special_Skill()
    {
        // Target이 죽었을시 새로운 Target을 받는다.
        if (Target.Check_Dead())
        {
            MonsterManager.Get_Inctance().Set_ReTarget(this);
        }

        //현재 Player의 회전값을 저장한후 회전값을 초기화한다.
        Quaternion InitRotation = gameObject.transform.rotation;

        transform.rotation = Quaternion.identity;

        // ActionCamera에게 Warrior의 애니메이션을 실행시키게 한다.
        ActionCamera_Action.Get_Inctance().Set_preparation(transform, "Warrior");

        // Warrior을 제외한 모든 Player, Monster의 Active를 false시킨다.
        PlayerManager.Get_Inctance().Players_Active(gameObject, "OFF");
        MonsterManager.Get_Inctance().Monsters_Active(null, "OFF");

        yield return(new WaitForSeconds(0.25f));

        ani.SetTrigger("SpecialSkill");

        yield return(new WaitForSeconds(0.35f));

        ani.speed = 0f;

        yield return(new WaitForSeconds(0.8f));

        ani.speed = 1f;
        ani.SetTrigger("Idle");

        // ActionCamera의 Camera를 끈다.
        ActionCamera_Action.Get_Inctance().CameraOff();

        // Warrior을 제외한 모든 Player, Monster의 Active를 true시킨다.
        PlayerManager.Get_Inctance().Players_Active(null, "ON");
        MonsterManager.Get_Inctance().Monsters_Active(null, "ON");

        // Player의 회전값을 원래대로 되돌린다.
        transform.rotation = InitRotation;

        // Target에게 데미지를 준다.
        Target.Set_Demage(Init_Infomation.Special_value, "Skill");

        // Player들을 Attack상태로 바꾼다. ( Active 변환 때문.)
        PlayerManager.Get_Inctance().Set_Attack();
        MonsterManager.Get_Inctance().Set_ReAttack();

        //SkillPoint를 초기화한다.
        SkillPoint = 0f;


        yield break;
    }
コード例 #3
0
    void OnEnable()
    {
        if (First_Appear == true)
        {
            return;
        }

        ActionCamera_Action.Get_Inctance().Set_preparation(transform, "Boss");

        First_Appear = true;
        type         = TYPE.BOSS;
        ani          = GetComponent <Animator>();
    }
コード例 #4
0
    public static ActionCamera_Action Get_Inctance()
    {
        if (instance == null)
        {
            instance = FindObjectOfType(typeof(ActionCamera_Action)) as ActionCamera_Action;
        }

        if (null == instance)
        {
            GameObject obj = new GameObject("ActionCamera ");
            instance = obj.AddComponent(typeof(ActionCamera_Action)) as ActionCamera_Action;

            Debug.Log("Fail to get Manager Instance");
        }
        return(instance);
    }
コード例 #5
0
    // Specal Skill이 작동하는 함수.
    IEnumerator C_Special_Skill()
    {
        // Target이 죽었을시 새로운 Target을 받는다.
        if (Target.Check_Dead())
        {
            MonsterManager.Get_Inctance().Set_ReTarget(this);
        }

        //현재 Player의 회전값을 저장한후 회전값을 초기화한다.
        Quaternion InitRotation = gameObject.transform.rotation;

        transform.rotation = Quaternion.identity;

        // ActionCamera에게 Wizard의 애니메이션을 실행시키게 한다.
        ActionCamera_Action.Get_Inctance().Set_preparation(transform, "Wizard");

        // Nurse를 제외한 모든 Player, Monster의 Active를 false시킨다.
        PlayerManager.Get_Inctance().Players_Active(gameObject, "OFF");
        MonsterManager.Get_Inctance().Monsters_Active(null, "OFF");

        yield return(new WaitForSeconds(0.25f));

        ani.SetTrigger("SpecialSkill");

        yield return(new WaitForSeconds(0.8f));

        ani.speed = 0f;

        yield return(new WaitForSeconds(0.4f));

        ani.speed = 1f;

        // Wizard의 두번째 카메라를 실행시킨다. ( 번개가 내릴때의 카메라 )
        ActionCamera_Action.Get_Inctance().Set_preparation(transform, "Wizard2");
        ani.speed = 0.8f;

        yield return(new WaitForSeconds(0.6f));

        // 스페셜 공격 Effect를 Target에 만든다.
        Set_SpecialSkill_Effect();
        ani.SetTrigger("Idle");
        // Target을 활성화하고 대기상태로 만든다.
        Target.gameObject.SetActive(true);
        Target.GetComponent <MonsterAction>().Set_AniIdle();

        // 스피드를 원래대로 되돌린다.
        ani.speed = 1f;

        yield return(new WaitForSeconds(0.7f));

        // ActionCamera의 Camera를 끈다.
        ActionCamera_Action.Get_Inctance().CameraOff();

        // Wizard를 제외한 모든 Player, Monster의 Active를 true시킨다.
        PlayerManager.Get_Inctance().Players_Active(null, "ON");
        MonsterManager.Get_Inctance().Monsters_Active(null, "ON");

        // Player의 회전값을 원래대로 되돌린다.
        transform.rotation = InitRotation;

        // Target이 Idle상태가 됬으니 다시 Attack을 실행하게 한다.
        Target.GetComponent <MonsterAction>().StartSet_Attack();

        // 모두를 Attack상태로 바꾼다. ( Active 변환 때문.)
        PlayerManager.Get_Inctance().Set_Attack();
        MonsterManager.Get_Inctance().Set_ReAttack();

        // Target에게 데미지를 준다.
        Target.Set_Demage(Init_Infomation.Special_value, "Skill");
        // SkillPoint를 초기화한다.
        SkillPoint = 0;
    }
コード例 #6
0
    // Use this for initialization
    void Awake()
    {
        instance = this;

        ani = GetComponent <Animator>();
    }