/// <summary> /// /// </summary> public void SetTouZiZero() { MJSenceRoot sRoot = Global.Inst.GetController <MJGameController>().mGameUI.mMJSceneRoot; for (int i = 0; i < sRoot.mTouzi.Length; i++) { Vector3 agule = sRoot.mTouzi[i].localRotation.eulerAngles; ; float a = 0f; Vector3 ver = new Vector3(1, 0, 0); if (agule.x != 0) { a = agule.x; } else if (agule.y != 0) { a = agule.y; } else if (agule.z != 0) { a = agule.z; ver = new Vector3(0, 0, 1); } sRoot.mTouzi[i].Rotate(ver, -a); } }
public void InitMJScene() { if (mMJSceneRoot == null) { mMJSceneRoot = GameObject.Find("MJBackSenceAll").GetComponent <MJSenceRoot>(); mSelfPlayer.mPlayer = mMJSceneRoot.mMyself; mMJSceneRoot.mMyself.mPlayerPosType = mSelfPlayer.mPlayerPosType; for (int i = 0; i < mOtherPlayer.Count; i++) { mOtherPlayer[i].mPlayer = mMJSceneRoot.mOther[i]; mMJSceneRoot.mOther[i].mPlayerPosType = mOtherPlayer[i].mPlayerPosType; } } }
public void SetTouZiView() { MJSenceRoot sRoot = Global.Inst.GetController <MJGameController>().mGameUI.mMJSceneRoot; sRoot.SetTouZiNum(MJGameModel.Inst.mStartGameData.startInfo.dices); }