using System.Collections; using System.Collections.Generic; using UnityEngine; public class ReplayFifteenLadder : ReplaySimpleObject { /// /// 回放克隆 /// /// public override void CloneObject(string json) { var jsonData = JsonUtility.FromJson(json); var clonedObj = EntitiesManager.Instance.CreateObj(cloneBase.clonePrefab, jsonData.myTransform.getMyPosition(), transform, long.Parse(jsonData.objectName)); clonedObj.name = jsonData.objectName;//名字即ID SetBaseGameObject(clonedObj, jsonData); clonedObj.transform.Find("LadderUp1").localPosition = jsonData.upLadderFstPos; clonedObj.transform.Find("LadderUp2").localPosition = jsonData.upLadderScdPos; SetCloneGameObject(clonedObj, json); if (clonedObj.GetComponent()) { clonedObj.GetComponent().SetSelect(json); } } }