예제 #1
0
파일: Actor.cs 프로젝트: 977567460/Escapes
    public void InitAction()
    {
        DBEntiny db = GameDataManage.Instance.GetDBEntiny(Id);

        if (db == null)
        {
            return;
        }
        mActorAnimator = GTTools.LoadAnimator(Obj, db.Ctrl);
        if (mActorAnimator != null)
        {
            mActorAnimator.enabled         = true;
            mActorAnimator.applyRootMotion = true;
            mActorAnimator.cullingMode     = AnimatorCullingMode.CullUpdateTransforms;
            this.mActorAction = new ZTAction(mActorAnimator);
        }
    }
예제 #2
0
파일: Actor.cs 프로젝트: mengtest/skilldemo
    protected void InitAction()
    {
        //DBEntiny db = ZTConfig.Instance.GetDBEntiny(Id);
        string ctrlstr = "Model/Actor/" + this.Id + "_Ctrl";

        //string ctrlstr = "Model/Actor/50006_Ctrl";
        //if (db == null)
        //{
        //    return;
        //}
        //mActorAnimator = GTTools.LoadAnimator(Obj, db.Ctrl);
        mActorAnimator = GTTools.LoadAnimator(Obj, ctrlstr);
        if (mActorAnimator != null)
        {
            mActorAnimator.enabled         = true;
            mActorAnimator.applyRootMotion = true;
            mActorAnimator.cullingMode     = AnimatorCullingMode.CullUpdateTransforms;
            this.mActorAction = new ZTAction(mActorAnimator);
        }
    }