/*-----------------------------------------------------------------------------------*/ // 選択回転開始前設定 public void OnSetupRotation(bool isRigth) { // 回転中は開始しない if (isRot) { return; } // 選択中のモデルの回転を停止 models[(int)type].StopRotation(); // 次のタイプへ設定 左右フラグで計算変更 if (isRigth) { type = (PIG_TYPE)((((int)type + 1)) % (int)PIG_TYPE.TYPE_NUM); } else { type = (PIG_TYPE)((((int)type - 1 + ((int)PIG_TYPE.TYPE_NUM))) % (int)PIG_TYPE.TYPE_NUM); } // 各コンポーネントの値を設定 SetComponentValue(); // 回転コルーチン開始 StartCoroutine(this.StartRotation(isRigth)); }
public void CmdSetSelectType(PIG_TYPE type) { SelectType = type; }
public void CmdSetupInfo(PIG_TYPE type) { // 基本ステータス取得 _Info = _ModelPrefabs[type.GetHashCode()].GetComponent <PigInfo>()._Info; }