public void addSaveData(CameraMoveData modeData)
 {
     if (saveDocument != null)
     {
         CAMERAMOVEDATALIST.Add(modeData.id, modeData);
         XmlNode    root    = saveDocument.SelectSingleNode("CameraPath");
         XmlElement element = modeData.save(saveDocument);
         root.AppendChild(element);
     }
 }
        public void loadData()
        {
            CAMERAMOVEDATALIST.Clear();
            XmlDocument cameraData = new XmlDocument();

            cameraData.LoadXml(Resources.Load(CAMERAMOVEDATA_PATH).ToString());
            XmlNodeList nodeList = cameraData.GetElementsByTagName("CameraPath")[0].ChildNodes;

            foreach (XmlElement xe in nodeList)
            {
                CameraMoveData data = new CameraMoveData();
                data.decode(xe);
                CAMERAMOVEDATALIST.Add(Convert.ToInt32(xe.GetAttribute("id")), data);
            }
        }
        //编辑器回放专用
        public void runScript(CameraMoveData data, bool editorMode = false)
        {
            _editorMode  = editorMode;
            _curPathData = data;

            _oraginCamera = CameraManager.Instance.CurCamera;
            if (_oraginCamera.CameraType == MTBCameraType.Third)
            {
                CameraManager.Instance.UseFirstPersonCamera();
            }
            _curControlCamera = CameraManager.Instance.CurCamera;

            _stepSum = _curPathData.steps.ToArray().Length;
            startPosition();
            _workMark = true;
            MTBUserInput.Instance.SetJoyStickActive(false);
            UIManager.Instance.closeUI(UITypes.MAIN_UI);
#if UNITY_EDITOR
            MTBKeyboard.setEnable(false);
#endif
        }