public override void ApplyDefaultState() { this.transform.set_position(PosDirUtility.ToTerrainPoint(this.originPos, 0f)); if (this.originDir.get_Count() >= 3) { this.transform.set_eulerAngles(PosDirUtility.ToEulerAnglesFromErrorFormatData(this.originDir)); } else { this.transform.set_eulerAngles(new Vector3(0f, (float)Random.Range(0, 360), 0f)); } }
protected void SetPositionAndRotation() { CaiJiPeiZhi caiJiPeiZhi = DataReader <CaiJiPeiZhi> .Get(this.collectionDataID); if (caiJiPeiZhi == null) { return; } if (caiJiPeiZhi.position.get_Count() >= 3) { this.transform.set_position(PosDirUtility.ToTerrainPoint(caiJiPeiZhi.position)); } if (caiJiPeiZhi.face.get_Count() >= 3) { this.transform.set_eulerAngles(PosDirUtility.ToEulerAnglesFromErrorFormatData(caiJiPeiZhi.face)); } }
protected void SetPositionAndRotation() { ChuanSongMenNPC chuanSongMenNPC = DataReader <ChuanSongMenNPC> .Get(this.hearthDataID); if (chuanSongMenNPC == null) { return; } if (chuanSongMenNPC.position.get_Count() >= 3) { this.transform.set_position(PosDirUtility.ToTerrainPoint(chuanSongMenNPC.position)); } if (chuanSongMenNPC.face.get_Count() >= 3) { this.transform.set_eulerAngles(PosDirUtility.ToEulerAnglesFromErrorFormatData(chuanSongMenNPC.face)); } }