QingXiCheAndQvCarEventClick.js 96 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432
  1. import { QingXiCheAndQvCarEvent } from "./QingXiCheAndQvCarEvent.js";
  2. import { QingXiCheAndQvComHighlightLayer } from "./QingXiCheAndQvComHighlightLayer.js";
  3. import { ComVal } from "../common/ComVal.js";
  4. import { WindowEvent } from "../../WindowQingXiCheAndQv/js/WindowEvent.js";
  5. import { QingXiCheAndQvComRes } from '../js/QingXiCheAndQvComRes.js';
  6. import { QingXiCheAndQvComClipPlaneMeshEvent } from './QingXiCheAndQvComClipPlaneMeshEvent.js';
  7. import { QingXiCheAdnQvCarEventStep } from './QingXiCheAdnQvCarEventStep.js';
  8. import { ElMessage, ElMessageBox } from 'element-plus';
  9. /**
  10. * 操作清洗车仿真 点击物体的时候触发 逻辑
  11. */
  12. export class QingXiCheAndQvCarEventClick {
  13. // 每次 new 出对象则会调用这个构造函数
  14. constructor() {
  15. /**
  16. * 三维世界对象 src\components\ThreeWorldEvent\js\QingXiCheAndQvThreeWorldEventMain.js
  17. */
  18. this.objThreeWorldEventMain = null;
  19. /**
  20. * 当前移动的物体列表,和对应的参数
  21. * 当数组存在目标的时候,则 拖拽的时候,目标物体跟着鼠标移动
  22. */
  23. this.moveMeshList = [];
  24. // 记录第一次点击拖拽时候的坐标
  25. this.moveMeshListClick = {
  26. "x" : 0, "y" : 0, "z" : 0
  27. };
  28. /**
  29. * 当前这些参数不等于null的时候,则说明再拖拽移动目标物体
  30. * 此时固定相机的坐标,和视角
  31. */
  32. this.moveCameraRadius = null;
  33. this.moveCameraAlpha = null;
  34. this.moveCameraBeta = null;
  35. // 记录最后因为 this.moveMeshList 逻辑,鼠标移动的坐标
  36. this.moveCoordinate = {
  37. "x" : 0, "y" : 0, "z" : 0
  38. };
  39. // 是否开启每帧判断的逻辑
  40. this.renderEventBool = false;
  41. // 记录 QingXiCheAndQvProcessEventStore
  42. this.QingXiCheAndQvProcessEventStore = null;
  43. }
  44. // 实现单例模式
  45. static find() {
  46. if (!QingXiCheAndQvCarEventClick.instance) {
  47. QingXiCheAndQvCarEventClick.instance = new QingXiCheAndQvCarEventClick();
  48. }
  49. return QingXiCheAndQvCarEventClick.instance;
  50. }
  51. /**
  52. * 鼠标点击的时候
  53. * pickResult 点击的具体坐标,物体等信息
  54. */
  55. clickMeshEvent = function(pickResult) {
  56. let thisClass = this;
  57. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  58. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  59. let objIframe = objThreeWorldEventMain.objIframe;
  60. let objScene = objThreeWorldEventMain.objScene;
  61. let BABYLON = objThreeWorldEventMain.BABYLON;
  62. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  63. // console.log(
  64. // "鼠标点击的时候", pickResult
  65. // );
  66. // 处理中则不做处理
  67. if (QingXiCheAndQvCarEvent.find().eventEnd != 0) {
  68. return this;
  69. }
  70. let type = QingXiCheAndQvCarEvent.find().eventName;
  71. let meshMoveConfig = thisClass.meshMoveConfig(type);
  72. if (meshMoveConfig == null) {
  73. thisClass.moveMeshListReset();
  74. return;
  75. }
  76. // 目标物体
  77. let pickedMesh = pickResult["pickedMesh"];
  78. if (typeof pickedMesh["id"] != "string") {
  79. return;
  80. }
  81. let meshId = pickedMesh["id"];
  82. // 点击的坐标
  83. let pickedPoint = pickResult["pickedPoint"];
  84. let meshList = meshMoveConfig["meshList"];
  85. let meshJson = meshMoveConfig["meshJson"];
  86. // 点击的不是在物体的列表里的时候
  87. if (meshJson[meshId] == null || meshJson[meshId] == undefined) {
  88. thisClass.moveMeshListReset();
  89. return;
  90. }
  91. let objSceneActiveCamera = ChengGuangYuanJing.CommonVal.find().objSceneActiveCamera;
  92. thisClass.moveCameraRadius = objSceneActiveCamera.radius;
  93. thisClass.moveCameraAlpha = objSceneActiveCamera.alpha;
  94. thisClass.moveCameraBeta = objSceneActiveCamera.beta;
  95. thisClass.moveMeshListClick = {
  96. "x" : pickedPoint.x, "y" : pickedPoint.y, "z" : pickedPoint.z
  97. };
  98. console.log(
  99. "thisClass.moveMeshListClick",
  100. thisClass.moveMeshListClick
  101. );
  102. thisClass.moveMeshList = [];
  103. // 记录点击的时候的物体的坐标
  104. for (let i = 0; i < meshList.length; i++) {
  105. let thisMeshId = meshList[i];
  106. let thisObjMesh = objScene.getMeshById(thisMeshId);
  107. if (thisObjMesh != null && thisObjMesh != undefined) {
  108. // 设置为不可选中
  109. thisObjMesh.isPickable = false;
  110. let addJson = {
  111. "meshId" : thisObjMesh.id,
  112. "x" : thisObjMesh.absolutePosition.x,
  113. "y" : thisObjMesh.absolutePosition.y,
  114. "z" : thisObjMesh.absolutePosition.z,
  115. };
  116. thisClass.moveMeshList.push(
  117. // 必须转换下,这样就是独立的对象
  118. JSON.parse(JSON.stringify(addJson))
  119. );
  120. }
  121. }
  122. return thisClass;
  123. }
  124. /**
  125. * 重置为不是拖拽逻辑
  126. */
  127. moveMeshListReset = function() {
  128. let thisClass = this;
  129. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  130. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  131. let objIframe = objThreeWorldEventMain.objIframe;
  132. let objScene = objThreeWorldEventMain.objScene;
  133. let BABYLON = objThreeWorldEventMain.BABYLON;
  134. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  135. // 先将对应的物体,恢复可以选中
  136. if (thisClass.moveMeshList.length > 0) {
  137. for (let i = 0; i < thisClass.moveMeshList.length; i++) {
  138. let thisConfig = thisClass.moveMeshList[i];
  139. let thisMeshId = thisConfig["meshId"];
  140. let thisObjMesh = objScene.getMeshById(thisMeshId);
  141. if (thisObjMesh != null && thisObjMesh != undefined) {
  142. // 设置为可选中
  143. thisObjMesh.isPickable = true;
  144. }
  145. }
  146. }
  147. thisClass.moveMeshList = [];
  148. thisClass.moveCameraRadius = null;
  149. thisClass.moveCameraAlpha = null;
  150. thisClass.moveCameraBeta = null;
  151. }
  152. /**
  153. * 更新被拖拽物体的位置
  154. */
  155. moveMeshListCoordinateUpdate = function() {
  156. let thisClass = this;
  157. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  158. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  159. let objIframe = objThreeWorldEventMain.objIframe;
  160. let objScene = objThreeWorldEventMain.objScene;
  161. let BABYLON = objThreeWorldEventMain.BABYLON;
  162. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  163. if (thisClass.moveMeshList.length > 0) {
  164. // 追加的xyz坐标
  165. var addPosition = {
  166. "x" : thisClass.moveCoordinate.x - thisClass.moveMeshListClick.x,
  167. "y" : thisClass.moveCoordinate.y - thisClass.moveMeshListClick.y,
  168. "z" : thisClass.moveCoordinate.z - thisClass.moveMeshListClick.z,
  169. };
  170. for (let i = 0; i < thisClass.moveMeshList.length; i++) {
  171. let thisConfig = thisClass.moveMeshList[i];
  172. let thisMeshId = thisConfig["meshId"];
  173. let thisObjMesh = objScene.getMeshById(thisMeshId);
  174. if (thisObjMesh != null && thisObjMesh != undefined) {
  175. // 一定要用绝对坐标更新,这样才可以解决不同模型轴向,问题导致设置 position 会各种出错
  176. thisObjMesh.setAbsolutePosition(
  177. new BABYLON.Vector3(
  178. parseFloat(thisConfig["x"]) + addPosition.x,
  179. parseFloat(thisConfig["y"]) + addPosition.y,
  180. parseFloat(thisConfig["z"]) + addPosition.z
  181. )
  182. );
  183. }
  184. }
  185. }
  186. }
  187. /**
  188. * 将当前的物体列表,回归到最初原始的坐标位置
  189. */
  190. moveMeshListResetPosition = function () {
  191. let thisClass = this;
  192. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  193. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  194. let objIframe = objThreeWorldEventMain.objIframe;
  195. let objScene = objThreeWorldEventMain.objScene;
  196. let BABYLON = objThreeWorldEventMain.BABYLON;
  197. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  198. if (thisClass.moveMeshList.length > 0) {
  199. for (let i = 0; i < thisClass.moveMeshList.length; i++) {
  200. let thisConfig = thisClass.moveMeshList[i];
  201. let thisMeshId = thisConfig["meshId"];
  202. let thisObjMesh = objScene.getMeshById(thisMeshId);
  203. if (thisObjMesh != null && thisObjMesh != undefined) {
  204. // 一定要用绝对坐标更新,这样才可以解决不同模型轴向,问题导致设置 position 会各种出错
  205. thisObjMesh.setAbsolutePosition(
  206. new BABYLON.Vector3(
  207. parseFloat(thisConfig["x"]),
  208. parseFloat(thisConfig["y"]),
  209. parseFloat(thisConfig["z"])
  210. )
  211. );
  212. }
  213. }
  214. }
  215. }
  216. /**
  217. * 鼠标移动的时候
  218. * pickResult 点击的具体坐标,物体等信息
  219. */
  220. clickMoveMeshEvent = function(pickResult) {
  221. let thisClass = this;
  222. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  223. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  224. let objIframe = objThreeWorldEventMain.objIframe;
  225. let objScene = objThreeWorldEventMain.objScene;
  226. let BABYLON = objThreeWorldEventMain.BABYLON;
  227. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  228. // console.log(
  229. // "鼠标移动的时候", pickResult
  230. // );
  231. // 处理中则不做处理
  232. if (QingXiCheAndQvCarEvent.find().eventEnd != 0) {
  233. return this;
  234. }
  235. // 此时移动的坐标
  236. let pickedPoint = pickResult["pickedPoint"];
  237. thisClass.moveCoordinate = {
  238. "x" : pickedPoint.x, "y" : pickedPoint.y, "z" : pickedPoint.z
  239. };
  240. thisClass.moveMeshListCoordinateUpdate();
  241. return thisClass;
  242. }
  243. /**
  244. * 判断是否拖拽到指定的坐标范围了
  245. * 范围内 返回 true , 否则返回 false
  246. */
  247. dragBool = function() {
  248. let thisClass = this;
  249. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  250. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  251. let objIframe = objThreeWorldEventMain.objIframe;
  252. let objScene = objThreeWorldEventMain.objScene;
  253. let BABYLON = objThreeWorldEventMain.BABYLON;
  254. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  255. // 当没有被点击的物体的时候,说明该逻辑是没有拖拽到附近的
  256. if (thisClass.moveMeshList.length <= 0) {
  257. return false;
  258. }
  259. // 最终应该拖拽到哪个坐标附近
  260. let targetPosition = {
  261. "x" : -0.00247241766192019,
  262. "y" : -0.8081836700439453,
  263. "z" : 36.005401611328125,
  264. }
  265. // 得到两点之间的距离
  266. let thisVector3distanceTo = BABYLON.Vector3.Distance(
  267. new BABYLON.Vector3(parseFloat(targetPosition.x), parseFloat(targetPosition.y), parseFloat(targetPosition.z)),
  268. new BABYLON.Vector3(parseFloat(thisClass.moveCoordinate.x), parseFloat(thisClass.moveCoordinate.y), parseFloat(thisClass.moveCoordinate.z))
  269. );
  270. // console.log(
  271. // "拖拽后的距离", thisVector3distanceTo
  272. // );
  273. if (thisVector3distanceTo <= 0.5) {
  274. return true;
  275. }
  276. return false;
  277. }
  278. /**
  279. * 每帧被执行,用于判断距离等情况使用
  280. */
  281. renderEvent = () => {
  282. let thisClass = this;
  283. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  284. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  285. let objIframe = objThreeWorldEventMain.objIframe;
  286. let objScene = objThreeWorldEventMain.objScene;
  287. let BABYLON = objThreeWorldEventMain.BABYLON;
  288. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  289. if (thisClass.renderEventBool == false) {
  290. return this;
  291. }
  292. if (QingXiCheAndQvCarEvent.find().eventEnd != 0) {
  293. return this;
  294. }
  295. let type = QingXiCheAndQvCarEvent.find().eventName;
  296. // console.log("每帧 renderEvent ---", type);
  297. switch (type) {
  298. case '行至车辆区域':
  299. let roleAndPositionTargetBool = objThreeWorldEventMain.roleAndPositionTargetBool();
  300. if (roleAndPositionTargetBool == true) {
  301. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  302. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  303. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  304. thisClass.renderEventBool = false;
  305. // 记录当前的视角,解决人物,切换到新的视角的时候,会出现一个很长的过度问题
  306. objThreeWorldEventMain.coordinateMoveSphereFollowUpdate();
  307. ElMessageBox.alert('恭喜你,完成了当前任务,请点击下一步继续', '提示', {
  308. confirmButtonText: '知道了',
  309. callback: (action) => {
  310. },
  311. });
  312. }
  313. break;
  314. case '绕车一周':
  315. // console.log("绕车一周 每帧执行");
  316. let aroundTheCarPointBool = objThreeWorldEventMain.aroundTheCarPointBool();
  317. // console.log("绕车一周 每帧执行 ---", aroundTheCarPointBool);
  318. if (aroundTheCarPointBool == true) {
  319. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  320. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  321. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  322. thisClass.renderEventBool = false;
  323. // 记录当前的视角,解决人物,切换到新的视角的时候,会出现一个很长的过度问题
  324. objThreeWorldEventMain.coordinateMoveSphereFollowUpdate();
  325. ElMessageBox.alert('恭喜你,完成了当前任务,请点击下一步继续', '提示', {
  326. confirmButtonText: '知道了',
  327. callback: (action) => {
  328. },
  329. });
  330. }
  331. break;
  332. }
  333. }
  334. /**
  335. * 鼠标弹起的时候
  336. * 根据点击到的物体,和当前的流程,触发对应的逻辑
  337. * pickResult 点击的具体坐标,物体等信息
  338. */
  339. main = (pickResult) => {
  340. let thisClass = this;
  341. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  342. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  343. let objIframe = objThreeWorldEventMain.objIframe;
  344. let objScene = objThreeWorldEventMain.objScene;
  345. let BABYLON = objThreeWorldEventMain.BABYLON;
  346. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  347. console.log("typeClick 111111", QingXiCheAndQvCarEvent.find().eventName, QingXiCheAndQvCarEvent.find().eventEnd);
  348. if (QingXiCheAndQvCarEvent.find().eventEnd != 0) {
  349. return this;
  350. }
  351. console.log("typeClick 222222", QingXiCheAndQvCarEvent.find().eventName, QingXiCheAndQvCarEvent.find().eventEnd);
  352. var objMesh = pickResult.pickedMesh;
  353. var objPosition = pickResult.pickedPoint;
  354. // 获取点击对象的方向【 一定要加上 true,否则载入的获取模型的方向,会有问题 】
  355. // eslint-disable-next-line no-unused-vars
  356. var getNormal = pickResult.getNormal(true);
  357. let type = QingXiCheAndQvCarEvent.find().eventName;
  358. let dragBool = thisClass.dragBool();
  359. switch(type) {
  360. // 仿真模拟
  361. case '仿真模拟':
  362. break;
  363. // 人物换装
  364. case '人物换装':
  365. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  366. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  367. // 切换成正在处理中
  368. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  369. // 切换视角
  370. objIframeEdit.modelPeopleLook(3);
  371. objIframeEdit.cameraVisualAngleGetListNameGpsTo("穿衣服_2");
  372. objIframeEdit.roleShow(false);
  373. let thisTime = new Date().getTime();
  374. // 控制延迟逻辑
  375. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  376. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  377. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('人物换装_鞋子', function() {
  378. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('人物换装_裤子', function() {
  379. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('人物换装_上衣', function() {
  380. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('人物换装_安全帽', function() {
  381. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  382. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  383. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  384. ElMessageBox.alert('恭喜你,完成了当前任务,请点击下一步继续', '提示', {
  385. confirmButtonText: '知道了',
  386. callback: (action) => {
  387. },
  388. });
  389. });
  390. });
  391. });
  392. });
  393. });
  394. }
  395. break;
  396. // 打开车门进入驾驶室
  397. case '打开车门进入驾驶室':
  398. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  399. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  400. // 切换成正在处理中
  401. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  402. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_打开左门', function() {
  403. // 切换视角
  404. objThreeWorldEventMain.coordinateMoveSphereFollowUpdate();
  405. objIframeEdit.modelPeopleLook(3);
  406. objIframeEdit.cameraVisualAngleGetListNameGpsTo("清洗车打开车门");
  407. objIframeEdit.roleShow(false);
  408. let thisTime = new Date().getTime();
  409. // 控制延迟逻辑
  410. // ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  411. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500 * 3, function(fpsEventAddRet) {
  412. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  413. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  414. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  415. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  416. ElMessageBox.alert('恭喜你,完成了当前任务,请点击下一步继续', '提示', {
  417. confirmButtonText: '知道了',
  418. callback: (action) => {
  419. },
  420. });
  421. });
  422. });
  423. }
  424. break;
  425. // 确认手刹已拉起档位是P档然后发动车辆
  426. case '确认手刹已拉起档位是P档然后发动车辆':
  427. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  428. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  429. // 切换成正在处理中
  430. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  431. // 切换视角
  432. objIframeEdit.modelPeopleLook(3);
  433. objIframeEdit.cameraVisualAngleGetListNameGpsTo("清洗车切换挡位到空挡");
  434. objIframeEdit.roleShow(false);
  435. let thisTime = new Date().getTime();
  436. // 控制延迟逻辑
  437. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  438. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  439. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  440. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  441. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  442. ElMessageBox.alert('恭喜你,完成了当前任务,请点击下一步继续', '提示', {
  443. confirmButtonText: '知道了',
  444. callback: (action) => {
  445. },
  446. });
  447. });
  448. }
  449. break;
  450. // 发动车辆
  451. case '发动车辆':
  452. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  453. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  454. // 切换成正在处理中
  455. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  456. // 切换视角
  457. objIframeEdit.modelPeopleLook(3);
  458. objIframeEdit.cameraVisualAngleGetListNameGpsTo("清洗车启动车辆");
  459. objIframeEdit.roleShow(false);
  460. let thisTime = new Date().getTime();
  461. // 控制延迟逻辑
  462. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  463. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  464. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_旋转钥匙', function() {
  465. QingXiCheAndQvCarEvent.find().carOpen(true);
  466. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  467. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  468. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  469. ElMessageBox.alert('恭喜你,完成了当前任务,请点击下一步继续', '提示', {
  470. confirmButtonText: '知道了',
  471. callback: (action) => {
  472. },
  473. });
  474. // // 切换视角
  475. // objIframeEdit.modelPeopleLook(3);
  476. // objIframeEdit.cameraVisualAngleGetListNameGpsTo("拧动钥匙发动车辆向上");
  477. // objIframeEdit.roleShow(false);
  478. // thisTime = new Date().getTime();
  479. // // 控制延迟逻辑
  480. // ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  481. // ComVal.find().fpsEventDel(fpsEventAddRet.code);
  482. // QingXiCheAndQvCarEvent.find().eventEnd = 2;
  483. // QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  484. // QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  485. // });
  486. });
  487. });
  488. }
  489. break;
  490. // 打开车辆双闪同时开启工作双闪灯
  491. case '打开车辆双闪同时开启工作双闪灯':
  492. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  493. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  494. // 控制延迟逻辑
  495. ComVal.find().fpsEventAdd("type_click_" + new Date().getTime(), {}, 1000, function(fpsEventAddRet) {
  496. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  497. // 切换成正在处理中
  498. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  499. QingXiCheAndQvCarEvent.find().carShuangShanOpen(true);
  500. // 切换视角
  501. objIframeEdit.modelPeopleLook(3);
  502. objIframeEdit.cameraVisualAngleGetListNameGpsTo("清洗车开启双闪");
  503. objIframeEdit.roleShow(false);
  504. let thisTime = new Date().getTime();
  505. // 控制延迟逻辑
  506. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  507. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  508. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  509. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  510. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  511. ElMessageBox.alert('恭喜你,完成了当前任务,请点击下一步继续', '提示', {
  512. confirmButtonText: '知道了',
  513. callback: (action) => {
  514. },
  515. });
  516. });
  517. });
  518. }
  519. break;
  520. // 踩下车辆离合器5秒
  521. case '踩下车辆离合器5秒':
  522. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  523. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  524. // 切换成正在处理中
  525. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  526. // 切换视角
  527. objIframeEdit.modelPeopleLook(3);
  528. objIframeEdit.cameraVisualAngleGetListNameGpsTo("手握方向盘");
  529. objIframeEdit.roleShow(false);
  530. let thisTime = new Date().getTime();
  531. // 控制延迟逻辑
  532. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500 * 2, function(fpsEventAddRet) {
  533. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  534. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('踩下车辆离合器5秒', function() {
  535. WindowEvent.find().WindowCountdownOpen(5, "自定义返回数据", function(WindowCountdownOpenRes) {
  536. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  537. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  538. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  539. ElMessageBox.alert('恭喜你,完成了当前任务,请点击下一步继续', '提示', {
  540. confirmButtonText: '知道了',
  541. callback: (action) => {
  542. },
  543. });
  544. });
  545. });
  546. });
  547. }
  548. break;
  549. // 按下取力器开关
  550. case '按下取力器开关':
  551. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  552. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  553. // 切换成正在处理中
  554. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  555. // 切换视角
  556. objIframeEdit.modelPeopleLook(3);
  557. // objIframeEdit.cameraVisualAngleGetListNameGpsTo("观察仪表盘指示目视");
  558. objIframeEdit.cameraVisualAngleGetListNameGpsTo("清洗车按下取力器开关");
  559. objIframeEdit.roleShow(false);
  560. let thisTime = new Date().getTime();
  561. // 控制延迟逻辑
  562. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  563. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  564. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  565. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  566. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  567. ElMessageBox.alert('恭喜你,完成了当前任务,请点击下一步继续', '提示', {
  568. confirmButtonText: '知道了',
  569. callback: (action) => {
  570. },
  571. });
  572. });
  573. }
  574. break;
  575. // 缓慢抬起离合器
  576. case '缓慢抬起离合器':
  577. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  578. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  579. // 切换成正在处理中
  580. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  581. // 切换视角
  582. objIframeEdit.modelPeopleLook(3);
  583. objIframeEdit.cameraVisualAngleGetListNameGpsTo("抬起离合器踏板2");
  584. objIframeEdit.roleShow(false);
  585. let thisTime = new Date().getTime();
  586. // 控制延迟逻辑
  587. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  588. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  589. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('缓慢抬起离合器', function() {
  590. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  591. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  592. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  593. ElMessageBox.alert('恭喜你,完成了当前任务,请点击下一步继续', '提示', {
  594. confirmButtonText: '知道了',
  595. callback: (action) => {
  596. },
  597. });
  598. });
  599. });
  600. }
  601. break;
  602. // 确定车辆双闪和工作箭头等是否正常
  603. case '确定车辆双闪和工作箭头等是否正常':
  604. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  605. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  606. // 切换成正在处理中
  607. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  608. // 切换视角
  609. objIframeEdit.modelPeopleLook(3);
  610. objIframeEdit.cameraVisualAngleGetListNameGpsTo("清洗车确定车辆双闪和工作箭头等是否正常");
  611. objIframeEdit.roleShow(false);
  612. let thisTime = new Date().getTime();
  613. // 控制延迟逻辑
  614. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  615. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  616. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  617. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  618. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  619. ElMessageBox.alert('恭喜你,完成了当前任务,请点击下一步继续', '提示', {
  620. confirmButtonText: '知道了',
  621. callback: (action) => {
  622. },
  623. });
  624. });
  625. }
  626. break;
  627. // 下车确定安全灯显示是否正常
  628. case '下车确定安全灯显示是否正常':
  629. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  630. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  631. // 切换成正在处理中
  632. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  633. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_关门', function() {
  634. // 切换视角
  635. objIframeEdit.modelPeopleLook(3);
  636. objIframeEdit.cameraVisualAngleGetListNameGpsTo("下车观察各项灯光");
  637. objIframeEdit.roleShow(false);
  638. let thisTime = new Date().getTime();
  639. // 控制延迟逻辑
  640. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  641. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  642. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  643. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  644. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  645. });
  646. });
  647. }
  648. break;
  649. // 在施工范围放置警示标识
  650. case '在施工范围放置警示标识':
  651. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  652. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  653. // 切换成正在处理中
  654. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  655. // 切换视角
  656. objThreeWorldEventMain.coordinateMoveSphereFollowUpdate();// 先记录下当前视角
  657. objIframeEdit.modelPeopleLook(3);
  658. objIframeEdit.cameraVisualAngleGetListNameGpsTo("清洗车摆放安全桩");
  659. objIframeEdit.roleShow(false);
  660. let thisTime = new Date().getTime();
  661. // 控制延迟逻辑
  662. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  663. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  664. QingXiCheAndQvComClipPlaneMeshEvent.find().anQuanZhuangLookYes(function() {
  665. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  666. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  667. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  668. ElMessageBox.alert('恭喜你,完成了当前任务,请点击下一步继续', '提示', {
  669. confirmButtonText: '知道了',
  670. callback: (action) => {
  671. },
  672. });
  673. });
  674. });
  675. }
  676. break;
  677. // 从水管固定座上拧下高压水管
  678. case '从水管固定座上拧下高压水管':
  679. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  680. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  681. // 切换成正在处理中
  682. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  683. // 切换视角
  684. objIframeEdit.modelPeopleLook(3);
  685. objIframeEdit.cameraVisualAngleGetListNameGpsTo("从水管固定座上拧下高压水管2");
  686. objIframeEdit.roleShow(false);
  687. let thisTime = new Date().getTime();
  688. // 控制延迟逻辑
  689. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  690. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  691. QingXiCheAndQvComClipPlaneMeshEvent.find().jieKaiLookYes(function() {
  692. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  693. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  694. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  695. });
  696. });
  697. }
  698. break;
  699. // 调整卷筒器到合适位置
  700. case '调整卷筒器到合适位置':
  701. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  702. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  703. // 切换成正在处理中
  704. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  705. // 切换视角
  706. objIframeEdit.modelPeopleLook(3);
  707. objIframeEdit.cameraVisualAngleGetListNameGpsTo("调整卷筒器到合适位置2");
  708. objIframeEdit.roleShow(false);
  709. let thisTime = new Date().getTime();
  710. // 控制延迟逻辑
  711. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  712. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  713. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_调整卷筒器到合适位置_打开_1', function() {
  714. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_调整卷筒器到合适位置_打开_2', function() {
  715. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  716. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  717. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  718. });
  719. });
  720. });
  721. }
  722. break;
  723. // 取出高压水管并放入布管器内
  724. case '取出高压水管并放入布管器内':
  725. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  726. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  727. // 切换成正在处理中
  728. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  729. // 切换视角
  730. objIframeEdit.modelPeopleLook(3);
  731. objIframeEdit.cameraVisualAngleGetListNameGpsTo("取出高压水管并放入布管器内2");
  732. objIframeEdit.roleShow(false);
  733. let thisTime = new Date().getTime();
  734. // 控制延迟逻辑
  735. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  736. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  737. QingXiCheAndQvComClipPlaneMeshEvent.find().zhuanDaoWeiLookYes(function() {
  738. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  739. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  740. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  741. });
  742. });
  743. }
  744. break;
  745. // 套上高压水管护管器
  746. case '套上高压水管护管器':
  747. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  748. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  749. // 切换成正在处理中
  750. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  751. // 切换视角
  752. objIframeEdit.modelPeopleLook(3);
  753. objIframeEdit.cameraVisualAngleGetListNameGpsTo("套上高压水管护管器2");
  754. objIframeEdit.roleShow(false);
  755. let thisTime = new Date().getTime();
  756. // 控制延迟逻辑
  757. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  758. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  759. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_套上高压水管护管器', function() {
  760. QingXiCheAndQvComClipPlaneMeshEvent.find().ruanGuanLookYes_1(function() {
  761. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  762. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  763. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  764. });
  765. });
  766. });
  767. }
  768. break;
  769. // 安装合适的高压喷头
  770. case '安装合适的高压喷头':
  771. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  772. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  773. // 切换成正在处理中
  774. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  775. // 切换视角
  776. objIframeEdit.modelPeopleLook(3);
  777. objIframeEdit.cameraVisualAngleGetListNameGpsTo("安装合适的高压喷头2");
  778. objIframeEdit.roleShow(false);
  779. let thisTime = new Date().getTime();
  780. // 控制延迟逻辑
  781. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  782. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  783. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_安装合适的高压喷头_打开箱子', function() {
  784. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_安装合适的高压喷头_喷头移动到对应位置', function() {
  785. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  786. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  787. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  788. });
  789. });
  790. });
  791. }
  792. break;
  793. // 将高压水管放入待施工的管道内
  794. case '将高压水管放入待施工的管道内':
  795. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  796. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  797. // 切换成正在处理中
  798. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  799. // 切换视角
  800. objIframeEdit.modelPeopleLook(3);
  801. objIframeEdit.cameraVisualAngleGetListNameGpsTo("将高压水管放入待施工的管道内2");
  802. objIframeEdit.roleShow(false);
  803. let thisTime = new Date().getTime();
  804. // 控制延迟逻辑
  805. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  806. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  807. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_将高压水管放入待施工的管道内_打开井盖', function() {
  808. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_高压水管护管器_弯曲', function() {
  809. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_安装合适的高压喷头_喷头移动到对应位置_下井', function() {
  810. });
  811. QingXiCheAndQvComClipPlaneMeshEvent.find().ruanGuanLookYes_2(function() {
  812. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  813. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  814. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  815. });
  816. });
  817. });
  818. });
  819. }
  820. break;
  821. // 在触屏操作面板上将管长清零
  822. case '在触屏操作面板上将管长清零':
  823. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  824. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  825. // 切换成正在处理中
  826. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  827. // 切换视角
  828. objIframeEdit.modelPeopleLook(3);
  829. objIframeEdit.cameraVisualAngleGetListNameGpsTo("在触屏操作面板上将管长清零2");
  830. objIframeEdit.roleShow(false);
  831. let thisTime = new Date().getTime();
  832. // 控制延迟逻辑
  833. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  834. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  835. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  836. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  837. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  838. });
  839. }
  840. break;
  841. // 在安全的情况开启冲水开关
  842. case '在安全的情况开启冲水开关':
  843. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  844. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  845. // 切换成正在处理中
  846. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  847. // 切换视角
  848. objIframeEdit.modelPeopleLook(3);
  849. objIframeEdit.cameraVisualAngleGetListNameGpsTo("在安全的情况开启冲水开关2");
  850. objIframeEdit.roleShow(false);
  851. let thisTime = new Date().getTime();
  852. // 控制延迟逻辑
  853. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  854. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  855. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  856. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  857. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  858. });
  859. }
  860. break;
  861. // 根据现场工况调节冲水压力
  862. case '根据现场工况调节冲水压力':
  863. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  864. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  865. // 切换成正在处理中
  866. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  867. // 切换视角
  868. objIframeEdit.modelPeopleLook(3);
  869. objIframeEdit.cameraVisualAngleGetListNameGpsTo("根据现场工况调节冲水压力2");
  870. objIframeEdit.roleShow(false);
  871. let thisTime = new Date().getTime();
  872. // 控制延迟逻辑
  873. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  874. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  875. QingXiCheAdnQvCarEventStep.find().waterEvent(true);
  876. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  877. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  878. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  879. });
  880. }
  881. break;
  882. // 疏通管道后减小油门到初始状态
  883. case '疏通管道后减小油门到初始状态':
  884. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  885. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  886. // 切换成正在处理中
  887. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  888. // 切换视角
  889. objIframeEdit.modelPeopleLook(3);
  890. objIframeEdit.cameraVisualAngleGetListNameGpsTo("疏通管道后减小油门到初始状态2");
  891. objIframeEdit.roleShow(false);
  892. let thisTime = new Date().getTime();
  893. // 控制延迟逻辑
  894. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  895. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  896. QingXiCheAdnQvCarEventStep.find().waterEvent(false);
  897. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  898. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  899. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  900. });
  901. }
  902. break;
  903. // 带压收回高压水管
  904. case '带压收回高压水管':
  905. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  906. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  907. // 切换成正在处理中
  908. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  909. // 切换视角
  910. objIframeEdit.modelPeopleLook(3);
  911. objIframeEdit.cameraVisualAngleGetListNameGpsTo("带压收回高压水管2");
  912. objIframeEdit.roleShow(false);
  913. let thisTime = new Date().getTime();
  914. // 控制延迟逻辑
  915. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  916. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  917. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  918. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  919. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  920. });
  921. }
  922. break;
  923. // 至触摸屏关闭冲水开关
  924. case '至触摸屏关闭冲水开关':
  925. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  926. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  927. // 切换成正在处理中
  928. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  929. // 切换视角
  930. objIframeEdit.modelPeopleLook(3);
  931. objIframeEdit.cameraVisualAngleGetListNameGpsTo("至触摸屏关闭冲水开关2");
  932. objIframeEdit.roleShow(false);
  933. let thisTime = new Date().getTime();
  934. // 控制延迟逻辑
  935. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  936. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  937. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  938. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  939. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  940. });
  941. }
  942. break;
  943. // 缓慢收回高压水管
  944. case '缓慢收回高压水管':
  945. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  946. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  947. // 切换成正在处理中
  948. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  949. // 切换视角
  950. objIframeEdit.modelPeopleLook(3);
  951. objIframeEdit.cameraVisualAngleGetListNameGpsTo("缓慢收回高压水管2");
  952. objIframeEdit.roleShow(false);
  953. let thisTime = new Date().getTime();
  954. // 控制延迟逻辑
  955. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  956. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  957. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_高压水管护管器_变直', function() {
  958. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_将高压水管放入待施工的管道内_关闭井盖', function() {
  959. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_安装合适的高压喷头_喷头移动到对应位置_地面', function() {
  960. });
  961. QingXiCheAndQvComClipPlaneMeshEvent.find().ruanGuanLookYes_3(function() {
  962. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  963. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  964. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  965. });
  966. });
  967. });
  968. });
  969. }
  970. break;
  971. // 拆卸高压喷头放入喷头机箱内
  972. case '拆卸高压喷头放入喷头机箱内':
  973. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  974. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  975. // 切换成正在处理中
  976. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  977. // 切换视角
  978. objIframeEdit.modelPeopleLook(3);
  979. objIframeEdit.cameraVisualAngleGetListNameGpsTo("拆卸高压喷头放入喷头机箱内2");
  980. objIframeEdit.roleShow(false);
  981. let thisTime = new Date().getTime();
  982. // 控制延迟逻辑
  983. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  984. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  985. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_喷头放入箱内', function() {
  986. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_箱子盖起', function() {
  987. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  988. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  989. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  990. });
  991. });
  992. });
  993. }
  994. break;
  995. // 收起高压水管将卷筒恢复到初始状态
  996. case '收起高压水管将卷筒恢复到初始状态':
  997. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  998. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  999. // 切换成正在处理中
  1000. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  1001. // 切换视角
  1002. objIframeEdit.modelPeopleLook(3);
  1003. objIframeEdit.cameraVisualAngleGetListNameGpsTo("收起高压水管将卷筒恢复到初始状态2");
  1004. objIframeEdit.roleShow(false);
  1005. let thisTime = new Date().getTime();
  1006. // 控制延迟逻辑
  1007. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  1008. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  1009. QingXiCheAndQvComClipPlaneMeshEvent.find().ruanGuanLookYes_4(function() {
  1010. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_高压水管护管器回到原始位置', function() {
  1011. QingXiCheAndQvComClipPlaneMeshEvent.find().zhuanDaoWeiLookYes_2(function() {
  1012. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_调整卷筒器到合适位置_关闭_1', function() {
  1013. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_调整卷筒器到合适位置_关闭_2', function() {
  1014. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  1015. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  1016. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  1017. });
  1018. });
  1019. });
  1020. });
  1021. });
  1022. });
  1023. }
  1024. break;
  1025. // 将高压水管拧到水管固定座
  1026. case '将高压水管拧到水管固定座':
  1027. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  1028. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  1029. // 切换成正在处理中
  1030. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  1031. // 切换视角
  1032. objIframeEdit.modelPeopleLook(3);
  1033. objIframeEdit.cameraVisualAngleGetListNameGpsTo("将高压水管拧到水管固定座2");
  1034. objIframeEdit.roleShow(false);
  1035. let thisTime = new Date().getTime();
  1036. // 控制延迟逻辑
  1037. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  1038. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  1039. QingXiCheAndQvComClipPlaneMeshEvent.find().jieKaiLookYes_2(function() {
  1040. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  1041. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  1042. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  1043. });
  1044. });
  1045. }
  1046. break;
  1047. // 回到驾驶室踩下车辆离合器5秒
  1048. case '回到驾驶室踩下车辆离合器5秒':
  1049. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  1050. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  1051. // 切换成正在处理中
  1052. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  1053. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('踩下车辆离合器5秒', function() {
  1054. WindowEvent.find().WindowCountdownOpen(5, "自定义返回数据", function(WindowCountdownOpenRes) {
  1055. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  1056. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  1057. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  1058. });
  1059. });
  1060. }
  1061. break;
  1062. // 关闭取力器开关
  1063. case '关闭取力器开关':
  1064. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  1065. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  1066. // 切换成正在处理中
  1067. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  1068. // 切换视角
  1069. objIframeEdit.modelPeopleLook(3);
  1070. objIframeEdit.cameraVisualAngleGetListNameGpsTo("观察仪表盘指示目视");
  1071. objIframeEdit.roleShow(false);
  1072. let thisTime = new Date().getTime();
  1073. // 控制延迟逻辑
  1074. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  1075. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  1076. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  1077. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  1078. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  1079. });
  1080. }
  1081. break;
  1082. // 关闭车辆双闪和工作双闪箭头灯
  1083. case '关闭车辆双闪和工作双闪箭头灯':
  1084. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  1085. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  1086. // 切换成正在处理中
  1087. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  1088. QingXiCheAndQvCarEvent.find().carShuangShanOpen(false);
  1089. // 切换视角
  1090. objIframeEdit.modelPeopleLook(3);
  1091. objIframeEdit.cameraVisualAngleGetListNameGpsTo("打开工作双闪箭头灯");
  1092. objIframeEdit.roleShow(false);
  1093. let thisTime = new Date().getTime();
  1094. // 控制延迟逻辑
  1095. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  1096. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  1097. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  1098. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  1099. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  1100. });
  1101. }
  1102. break;
  1103. // 车辆正常熄火
  1104. case '车辆正常熄火':
  1105. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  1106. QingXiCheAdnQvCarEventStep.find().meshVisibility("all", false);
  1107. // 切换成正在处理中
  1108. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  1109. // 切换视角
  1110. objIframeEdit.modelPeopleLook(3);
  1111. objIframeEdit.cameraVisualAngleGetListNameGpsTo("拧动钥匙发动车辆");
  1112. objIframeEdit.roleShow(false);
  1113. let thisTime = new Date().getTime();
  1114. // 控制延迟逻辑
  1115. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  1116. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  1117. QingXiCheAdnQvCarEventStep.find().animationAllTypeUpdate('清洗车_钥匙关闭_熄火', function() {
  1118. QingXiCheAndQvCarEvent.find().carOpen(false);
  1119. // 切换视角
  1120. objIframeEdit.modelPeopleLook(3);
  1121. objIframeEdit.cameraVisualAngleGetListNameGpsTo("拧动钥匙发动车辆向上");
  1122. objIframeEdit.roleShow(false);
  1123. thisTime = new Date().getTime();
  1124. // 控制延迟逻辑
  1125. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  1126. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  1127. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  1128. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  1129. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  1130. });
  1131. });
  1132. });
  1133. }
  1134. break;
  1135. // //
  1136. // case '':
  1137. // break;
  1138. // //
  1139. // case '':
  1140. // break;
  1141. // 已完成所有任务
  1142. case 'equipmentRepositioningWork':
  1143. break;
  1144. // 数字修复虚拟仿真-将阀门关闭停止水流
  1145. case '数字修复虚拟仿真-将阀门关闭停止水流':
  1146. if (QingXiCheAdnQvCarEventStep.find().meshListBool(type, objMesh.id) == true) {
  1147. // 切换成正在处理中
  1148. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  1149. // 切换视角
  1150. objIframeEdit.modelPeopleLook(3);
  1151. objIframeEdit.cameraVisualAngleGetListNameGpsTo("关闭阀门完成");
  1152. objIframeEdit.roleShow(false);
  1153. let thisTime = new Date().getTime();
  1154. // 控制延迟逻辑
  1155. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  1156. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  1157. // 停止水流
  1158. QingXiCheAdnQvCarEventStep.find().waterGuanEvent(false);
  1159. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  1160. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  1161. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  1162. });
  1163. }
  1164. break;
  1165. // 数字修复虚拟仿真-将橡胶垫片放置到正确的位置
  1166. case '数字修复虚拟仿真-将橡胶垫片放置到正确的位置':
  1167. // 切换成正在处理中
  1168. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  1169. // 范围内
  1170. if (dragBool == true) {
  1171. // 回到原始位置
  1172. thisClass.moveMeshListResetPosition();
  1173. WindowEvent.find().WindowTxtViewOpenEvent(
  1174. // "现在播放橡胶垫片安装过程\n"
  1175. // +
  1176. "各类机械设备的法兰连接、轴承密封、泵体密封等部位都需要使用橡胶垫片,以保证设备的正常运行,防止润滑油、液压油等泄漏"
  1177. );
  1178. // WindowEvent.find().WindowVideoViewOpenEvent(
  1179. // QingXiCheAndQvCarEvent.find().videoJson["02"],
  1180. // { "自定义回调的字段" : "自定义回调的字段111" },
  1181. // function(WindowVideoViewOpenEventRes) {
  1182. // console.log(
  1183. // "WindowVideoViewOpenEventRes", WindowVideoViewOpenEventRes
  1184. // );
  1185. // }
  1186. // );
  1187. // 切换视角
  1188. objIframeEdit.modelPeopleLook(3);
  1189. objIframeEdit.cameraVisualAngleGetListNameGpsTo("将橡胶垫片放置到正确的位置_完成");
  1190. objIframeEdit.roleShow(false);
  1191. let thisTime = new Date().getTime();
  1192. // 控制延迟逻辑
  1193. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  1194. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  1195. thisClass.xiangJiaoDianPianOk(function() {
  1196. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  1197. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  1198. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  1199. });
  1200. });
  1201. } else {
  1202. // 回到原始位置
  1203. thisClass.moveMeshListResetPosition();
  1204. // 范围外
  1205. QingXiCheAndQvCarEvent.find().eventEnd = 0;
  1206. }
  1207. break;
  1208. // 数字修复虚拟仿真-将抱箍放置到正确的位置
  1209. case '数字修复虚拟仿真-将抱箍放置到正确的位置':
  1210. // 切换成正在处理中
  1211. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  1212. // 范围内
  1213. if (dragBool == true) {
  1214. // 回到原始位置
  1215. thisClass.moveMeshListResetPosition();
  1216. WindowEvent.find().WindowTxtViewOpenEvent(
  1217. // "现在播放橡抱箍安装过程\n"
  1218. // +
  1219. "抱箍是一种用于抱住或箍住其他材料的紧固件,通过将两个或多个部件紧紧固定在一起,起到连接、支撑或加固的作用."
  1220. + "通常由箍板、翼板、拉结筋板、螺栓及内衬垫构成。其中,箍板是主要的抱紧部件,翼板用于增加连接面积或提供额外的支撑点,拉结筋板则增强箍板的强度和稳定性,螺栓用于将抱箍紧固,内衬垫则可增加摩擦力或保护被箍物体的表面"
  1221. );
  1222. // 切换视角
  1223. objIframeEdit.modelPeopleLook(3);
  1224. objIframeEdit.cameraVisualAngleGetListNameGpsTo("将抱箍放置到正确的位置_完成");
  1225. objIframeEdit.roleShow(false);
  1226. let thisTime = new Date().getTime();
  1227. // 控制延迟逻辑
  1228. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  1229. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  1230. thisClass.baoGuOk(function() {
  1231. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  1232. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  1233. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  1234. });
  1235. });
  1236. } else {
  1237. // 回到原始位置
  1238. thisClass.moveMeshListResetPosition();
  1239. // 范围外
  1240. QingXiCheAndQvCarEvent.find().eventEnd = 0;
  1241. }
  1242. break;
  1243. // 数字修复虚拟仿真-将插销安装到正确的位置
  1244. case '数字修复虚拟仿真-将插销安装到正确的位置':
  1245. // 切换成正在处理中
  1246. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  1247. // 范围内
  1248. if (dragBool == true) {
  1249. // 回到原始位置
  1250. thisClass.moveMeshListResetPosition();
  1251. WindowEvent.find().WindowTxtViewOpenEvent(
  1252. // "现在播放插销安装过程\n"
  1253. // +
  1254. "通过将销杆插入对应的销孔中,实现物体之间的连接或锁定。利用销杆与销孔之间的配合精度和摩擦力,保持连接的稳定性。带有锁止机构的插销,通过特定的操作(如旋转、按压等)使锁止部件卡住销杆,防止其意外拔出,增强锁定效果。"
  1255. );
  1256. // 切换视角
  1257. objIframeEdit.modelPeopleLook(3);
  1258. objIframeEdit.cameraVisualAngleGetListNameGpsTo("将插销安装到正确的位置_完成");
  1259. objIframeEdit.roleShow(false);
  1260. let thisTime = new Date().getTime();
  1261. // 控制延迟逻辑
  1262. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  1263. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  1264. thisClass.chaXiaoOk(function() {
  1265. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  1266. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  1267. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  1268. });
  1269. });
  1270. } else {
  1271. // 回到原始位置
  1272. thisClass.moveMeshListResetPosition();
  1273. // 范围外
  1274. QingXiCheAndQvCarEvent.find().eventEnd = 0;
  1275. }
  1276. break;
  1277. // 数字修复虚拟仿真-将螺丝安装到正确的位置
  1278. case '数字修复虚拟仿真-将螺丝安装到正确的位置':
  1279. // 切换成正在处理中
  1280. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  1281. // 范围内
  1282. if (dragBool == true) {
  1283. // 回到原始位置
  1284. thisClass.moveMeshListResetPosition();
  1285. WindowEvent.find().WindowTxtViewOpenEvent(
  1286. // "现在播放螺丝安装过程\n"
  1287. // +
  1288. "螺丝通常由头部和螺纹杆两部分组成。头部有不同的形状,如圆形、方形、六角形等,以便使用相应的工具进行拧紧或松开操作。螺纹杆上有螺旋状的螺纹,用于与螺母或带有内螺纹的部件配合。"
  1289. );
  1290. // 切换视角
  1291. objIframeEdit.modelPeopleLook(3);
  1292. objIframeEdit.cameraVisualAngleGetListNameGpsTo("将螺丝安装到正确的位置_完成");
  1293. objIframeEdit.roleShow(false);
  1294. let thisTime = new Date().getTime();
  1295. // 控制延迟逻辑
  1296. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  1297. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  1298. thisClass.luoSiOk(function() {
  1299. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  1300. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  1301. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  1302. });
  1303. });
  1304. } else {
  1305. // 回到原始位置
  1306. thisClass.moveMeshListResetPosition();
  1307. // 范围外
  1308. QingXiCheAndQvCarEvent.find().eventEnd = 0;
  1309. }
  1310. break;
  1311. // 数字修复虚拟仿真-用扳手将螺丝旋紧螺丝
  1312. case '数字修复虚拟仿真-用扳手将螺丝旋紧螺丝':
  1313. // 切换成正在处理中
  1314. QingXiCheAndQvCarEvent.find().eventEnd = 1;
  1315. // 范围内
  1316. if (dragBool == true) {
  1317. // 回到原始位置
  1318. thisClass.moveMeshListResetPosition();
  1319. WindowEvent.find().WindowTxtViewOpenEvent(
  1320. // "现在播放扳手使用过程\n"
  1321. // +
  1322. "扳手通常由头部和手柄两部分组成。头部是与螺栓或螺母接触并施加扭矩的部分,根据不同的类型有各种形状和结构;手柄则用于握持和施加力,一般为杆状,以提供足够的杠杆作用。"
  1323. );
  1324. // 切换视角
  1325. objIframeEdit.modelPeopleLook(3);
  1326. objIframeEdit.cameraVisualAngleGetListNameGpsTo("用扳手将螺丝旋紧螺丝_完成");
  1327. objIframeEdit.roleShow(false);
  1328. let thisTime = new Date().getTime();
  1329. // 控制延迟逻辑
  1330. ComVal.find().fpsEventAdd("type_click_" + thisTime, {}, 1500, function(fpsEventAddRet) {
  1331. ComVal.find().fpsEventDel(fpsEventAddRet.code);
  1332. thisClass.banShouOk(function() {
  1333. QingXiCheAndQvCarEvent.find().eventEnd = 2;
  1334. QingXiCheAndQvCarEvent.find().tipsBtnsUpOpenEventCallbackMain(false);
  1335. QingXiCheAndQvCarEvent.find().tipsBtnsDownOpenEventCallbackMain(true);
  1336. });
  1337. });
  1338. } else {
  1339. // 回到原始位置
  1340. thisClass.moveMeshListResetPosition();
  1341. // 范围外
  1342. QingXiCheAndQvCarEvent.find().eventEnd = 0;
  1343. }
  1344. break;
  1345. // //
  1346. // case '':
  1347. // break;
  1348. // //
  1349. // case '':
  1350. // break;
  1351. default:
  1352. break;
  1353. }
  1354. // 上面执行完成,固定执行如下逻辑
  1355. thisClass.moveMeshListReset();
  1356. }
  1357. /**
  1358. * 根据不同类型,触发对应物体列表高亮逻辑
  1359. * type 对应类型操作高亮
  1360. */
  1361. meshListComHighlightEvent = (type) => {
  1362. let thisClass = this;
  1363. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  1364. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  1365. let objIframe = objThreeWorldEventMain.objIframe;
  1366. let objScene = objThreeWorldEventMain.objScene;
  1367. let BABYLON = objThreeWorldEventMain.BABYLON;
  1368. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  1369. let meshList = [];
  1370. // QingXiCheAndQvComHighlightLayer.find().delAll("自定义");
  1371. // 默认不闪烁
  1372. QingXiCheAndQvComHighlightLayer.find().flickerBool = false;
  1373. switch (type) {
  1374. case "数字修复虚拟仿真-将阀门关闭停止水流":
  1375. meshList = [
  1376. "model_1746598895146阀门_primitive0",
  1377. "model_1746598895146阀门_primitive1",
  1378. ];
  1379. // 开启闪烁逻辑
  1380. QingXiCheAndQvComHighlightLayer.find().flickerBool = true;
  1381. break;
  1382. case "数字修复虚拟仿真-将橡胶垫片放置到正确的位置":
  1383. meshList = [
  1384. "model_1746598895146橡胶垫",
  1385. ];
  1386. // 开启闪烁逻辑
  1387. QingXiCheAndQvComHighlightLayer.find().flickerBool = true;
  1388. break;
  1389. case "数字修复虚拟仿真-将抱箍放置到正确的位置":
  1390. meshList = [
  1391. "model_1746598895146上箍",
  1392. "model_1746598895146插销轴",
  1393. "model_1746598895146下箍",
  1394. ];
  1395. // 开启闪烁逻辑
  1396. QingXiCheAndQvComHighlightLayer.find().flickerBool = true;
  1397. break;
  1398. case "数字修复虚拟仿真-将插销安装到正确的位置":
  1399. meshList = [
  1400. "model_1746598895146插销1",
  1401. "model_1746598895146插销2",
  1402. ];
  1403. // 开启闪烁逻辑
  1404. QingXiCheAndQvComHighlightLayer.find().flickerBool = true;
  1405. break;
  1406. case "数字修复虚拟仿真-将螺丝安装到正确的位置":
  1407. meshList = [
  1408. "model_1746598895146紧箍螺丝01",
  1409. "model_1746598895146紧箍螺丝02",
  1410. "model_1746598895146紧箍螺丝03",
  1411. ];
  1412. // 开启闪烁逻辑
  1413. QingXiCheAndQvComHighlightLayer.find().flickerBool = true;
  1414. break;
  1415. case "数字修复虚拟仿真-用扳手将螺丝旋紧螺丝":
  1416. meshList = [
  1417. "model_1746598895146扳手",
  1418. ];
  1419. // 开启闪烁逻辑
  1420. QingXiCheAndQvComHighlightLayer.find().flickerBool = true;
  1421. break;
  1422. case "":
  1423. break;
  1424. }
  1425. for (let i = 0; i < meshList.length; i++) {
  1426. let meshId = meshList[i];
  1427. let objMesh = objScene.getMeshById(meshId);
  1428. if (objMesh != null && objMesh != undefined) {
  1429. // console.log(
  1430. // "添加发光的物体", meshId, objMesh
  1431. // );
  1432. // 先去除
  1433. QingXiCheAndQvComHighlightLayer.find().delMesh("自定义", objMesh);
  1434. // 在添加
  1435. QingXiCheAndQvComHighlightLayer.find().addMesh("自定义", objMesh, "rgb(79, 185, 255)");
  1436. }
  1437. }
  1438. }
  1439. /**
  1440. * 配置被拖拽物体的列表
  1441. * type 类型,根据不同类型进行获取
  1442. */
  1443. meshMoveConfig = function(type) {
  1444. let meshList = [];
  1445. switch(type) {
  1446. case "数字修复虚拟仿真-将橡胶垫片放置到正确的位置":
  1447. meshList = [
  1448. "model_1746598895146橡胶垫",
  1449. ];
  1450. break;
  1451. case "数字修复虚拟仿真-将抱箍放置到正确的位置":
  1452. meshList = [
  1453. "model_1746598895146上箍",
  1454. "model_1746598895146插销轴",
  1455. "model_1746598895146下箍",
  1456. ];
  1457. break;
  1458. case "数字修复虚拟仿真-将插销安装到正确的位置":
  1459. meshList = [
  1460. "model_1746598895146插销1",
  1461. "model_1746598895146插销2",
  1462. ];
  1463. break;
  1464. case "数字修复虚拟仿真-将螺丝安装到正确的位置":
  1465. meshList = [
  1466. "model_1746598895146紧箍螺丝01",
  1467. "model_1746598895146紧箍螺丝02",
  1468. "model_1746598895146紧箍螺丝03",
  1469. ];
  1470. break;
  1471. case "数字修复虚拟仿真-用扳手将螺丝旋紧螺丝":
  1472. meshList = [
  1473. "model_1746598895146扳手",
  1474. ];
  1475. break;
  1476. case "":
  1477. break;
  1478. }
  1479. if (meshList.length <= 0) {
  1480. return null;
  1481. }
  1482. let meshJson = {};
  1483. for (let i = 0; i < meshList.length; i++) {
  1484. let meshId = meshList[i];
  1485. meshJson[meshId] = meshId;
  1486. }
  1487. return {
  1488. "meshList" : meshList,
  1489. "meshJson" : meshJson,
  1490. };
  1491. }
  1492. /**
  1493. * 数字修复虚拟仿真-将橡胶垫片放置到正确的位置
  1494. * callback 开启完成回调
  1495. */
  1496. xiangJiaoDianPianOk = (callback) => {
  1497. let thisClass = this;
  1498. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  1499. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  1500. let objIframe = objThreeWorldEventMain.objIframe;
  1501. let objScene = objThreeWorldEventMain.objScene;
  1502. let BABYLON = objThreeWorldEventMain.BABYLON;
  1503. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  1504. // 播放动画列表
  1505. let playList = [
  1506. { "name" : "橡胶垫.001", "speed" : 2, "from" : 0, "to" : 200 },
  1507. ];
  1508. // 动画播放完成次数
  1509. let playEndNum = 0;
  1510. for (let i = 0; i < playList.length; i++) {
  1511. let thisPlayList = playList[i];
  1512. ChengGuangYuanJing.CommonVal.find().animationGroupsEventCallback(
  1513. thisPlayList.name, 'start', thisPlayList.speed, thisPlayList.from, thisPlayList.to, false, null,
  1514. function(state, objAnimation) {
  1515. if (state == "播放完成") {
  1516. playEndNum += 1;
  1517. if (playEndNum >= playList.length) {
  1518. callback("yes");
  1519. }
  1520. }
  1521. }
  1522. );
  1523. }
  1524. }
  1525. /**
  1526. * 数字修复虚拟仿真-将抱箍放置到正确的位置
  1527. * callback 开启完成回调
  1528. */
  1529. baoGuOk = (callback) => {
  1530. let thisClass = this;
  1531. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  1532. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  1533. let objIframe = objThreeWorldEventMain.objIframe;
  1534. let objScene = objThreeWorldEventMain.objScene;
  1535. let BABYLON = objThreeWorldEventMain.BABYLON;
  1536. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  1537. // 播放动画列表
  1538. let playList = [
  1539. { "name" : "上箍", "speed" : 2, "from" : 0, "to" : 300 },
  1540. { "name" : "插销轴.001", "speed" : 2, "from" : 0, "to" : 200 },
  1541. { "name" : "下箍.001", "speed" : 2, "from" : 0, "to" : 300 },
  1542. ];
  1543. // 动画播放完成次数
  1544. let playEndNum = 0;
  1545. for (let i = 0; i < playList.length; i++) {
  1546. let thisPlayList = playList[i];
  1547. ChengGuangYuanJing.CommonVal.find().animationGroupsEventCallback(
  1548. thisPlayList.name, 'start', thisPlayList.speed, thisPlayList.from, thisPlayList.to, false, null,
  1549. function(state, objAnimation) {
  1550. if (state == "播放完成") {
  1551. playEndNum += 1;
  1552. if (playEndNum >= playList.length) {
  1553. callback("yes");
  1554. }
  1555. }
  1556. }
  1557. );
  1558. }
  1559. }
  1560. /**
  1561. * 数字修复虚拟仿真-将插销安装到正确的位置
  1562. * callback 开启完成回调
  1563. */
  1564. chaXiaoOk = function(callback) {
  1565. let thisClass = this;
  1566. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  1567. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  1568. let objIframe = objThreeWorldEventMain.objIframe;
  1569. let objScene = objThreeWorldEventMain.objScene;
  1570. let BABYLON = objThreeWorldEventMain.BABYLON;
  1571. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  1572. // 播放动画列表
  1573. let playList = [
  1574. { "name" : "插销1.001", "speed" : 2, "from" : 300, "to" : 400 },
  1575. { "name" : "插销2.001", "speed" : 2, "from" : 300, "to" : 400 },
  1576. ];
  1577. // 动画播放完成次数
  1578. let playEndNum = 0;
  1579. for (let i = 0; i < playList.length; i++) {
  1580. let thisPlayList = playList[i];
  1581. ChengGuangYuanJing.CommonVal.find().animationGroupsEventCallback(
  1582. thisPlayList.name, 'start', thisPlayList.speed, thisPlayList.from, thisPlayList.to, false, null,
  1583. function(state, objAnimation) {
  1584. if (state == "播放完成") {
  1585. playEndNum += 1;
  1586. if (playEndNum >= playList.length) {
  1587. callback("yes");
  1588. }
  1589. }
  1590. }
  1591. );
  1592. }
  1593. }
  1594. /**
  1595. * 数字修复虚拟仿真-将螺丝安装到正确的位置
  1596. * callback 开启完成回调
  1597. */
  1598. luoSiOk = function(callback) {
  1599. let thisClass = this;
  1600. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  1601. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  1602. let objIframe = objThreeWorldEventMain.objIframe;
  1603. let objScene = objThreeWorldEventMain.objScene;
  1604. let BABYLON = objThreeWorldEventMain.BABYLON;
  1605. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  1606. // 播放动画列表
  1607. let playList = [
  1608. { "name" : "紧箍螺丝01.001", "speed" : 2, "from" : 400, "to" : 502 },
  1609. { "name" : "紧箍螺丝02.001", "speed" : 2, "from" : 400, "to" : 502 },
  1610. { "name" : "紧箍螺丝03|", "speed" : 2, "from" : 400, "to" : 502 },
  1611. ];
  1612. // 动画播放完成次数
  1613. let playEndNum = 0;
  1614. for (let i = 0; i < playList.length; i++) {
  1615. let thisPlayList = playList[i];
  1616. ChengGuangYuanJing.CommonVal.find().animationGroupsEventCallback(
  1617. thisPlayList.name, 'start', thisPlayList.speed, thisPlayList.from, thisPlayList.to, false, null,
  1618. function(state, objAnimation) {
  1619. if (state == "播放完成") {
  1620. playEndNum += 1;
  1621. if (playEndNum >= playList.length) {
  1622. callback("yes");
  1623. }
  1624. }
  1625. }
  1626. );
  1627. }
  1628. }
  1629. /**
  1630. * 数字修复虚拟仿真-用扳手将螺丝旋紧螺丝
  1631. * callback 开启完成回调
  1632. */
  1633. banShouOk = function(callback) {
  1634. let thisClass = this;
  1635. let objThreeWorldEventMain = this.objThreeWorldEventMain;
  1636. let objIframeEdit = objThreeWorldEventMain.objIframeEdit;
  1637. let objIframe = objThreeWorldEventMain.objIframe;
  1638. let objScene = objThreeWorldEventMain.objScene;
  1639. let BABYLON = objThreeWorldEventMain.BABYLON;
  1640. let ChengGuangYuanJing = objIframe.ChengGuangYuanJing;
  1641. // 播放动画列表
  1642. let playList = [
  1643. { "name" : "扳手.001", "speed" : 2, "from" : 500, "to" : 802 },
  1644. ];
  1645. // 动画播放完成次数
  1646. let playEndNum = 0;
  1647. for (let i = 0; i < playList.length; i++) {
  1648. let thisPlayList = playList[i];
  1649. ChengGuangYuanJing.CommonVal.find().animationGroupsEventCallback(
  1650. thisPlayList.name, 'start', thisPlayList.speed, thisPlayList.from, thisPlayList.to, false, null,
  1651. function(state, objAnimation) {
  1652. if (state == "播放完成") {
  1653. playEndNum += 1;
  1654. if (playEndNum >= playList.length) {
  1655. callback("yes");
  1656. }
  1657. }
  1658. }
  1659. );
  1660. }
  1661. }
  1662. }