删除日志
This commit is contained in:
parent
f5a2ca8eaf
commit
6bc46647d7
|
@ -7,10 +7,6 @@ const BASE_UPLOAD_API = store.state.user.uploadUrl;
|
|||
// export const BASE_ASSET_API = store.state.user.resourcesUrl;
|
||||
export const BASE_ASSET_API = store.state.user.ossUrl;
|
||||
|
||||
// console.log(JL3D_LOCAL_STATIC);
|
||||
// console.log(BASE_UPLOAD_API);
|
||||
// console.log(BASE_ASSET_API);
|
||||
|
||||
export function getUploadModelUrl() {
|
||||
return (BASE_UPLOAD_API+"/api/upload/MODEL?appId=00001&appSecret=joylink00001");
|
||||
}
|
||||
|
|
|
@ -332,7 +332,6 @@ export default {
|
|||
methods: {
|
||||
handleEdit(row, column, index) {
|
||||
this.$set(row, 'isEdit', true);
|
||||
// console.log(this.$refs);
|
||||
// if (this.$refs.customerInput.length) {
|
||||
// this.$refs.customerInput[index].$el.querySelector('input').focus();
|
||||
// }
|
||||
|
|
|
@ -48,7 +48,6 @@ export function Pathaction(){
|
|||
|
||||
document.onmousedown = function(event){
|
||||
jlmap3dedit.selectswitch = false;
|
||||
console.log(event.button);
|
||||
|
||||
//辅助线段
|
||||
|
||||
|
@ -60,7 +59,6 @@ export function Pathaction(){
|
|||
|
||||
lineswitch = null;
|
||||
|
||||
console.log(linenew);
|
||||
|
||||
if(linenew){
|
||||
|
||||
|
@ -74,7 +72,6 @@ export function Pathaction(){
|
|||
|
||||
point1 = mouserray(event,jlmap3dedit);
|
||||
|
||||
console.log("new");
|
||||
if(point1){
|
||||
linenew = addline(point1,1,jlmap3dedit.splineHelperObjects,jlmap3dedit.scene);
|
||||
jlmap3dedit.mapdata.path.push(linenew);
|
||||
|
@ -104,7 +101,6 @@ export function Pathaction(){
|
|||
jlmap3dedit.mapdata.sectionlist.sections.datalist[i].rail.push(linenew.geometry.vertices[n]);
|
||||
}
|
||||
jlmap3dedit.mapdata.sectionlist.sections.datalist[i].railline = linenew;
|
||||
console.log(jlmap3dedit.mapdata.sectionlist.sections.datalist[i].rail);
|
||||
i = jlmap3dedit.mapdata.sectionlist.sections.modellist.length;
|
||||
}
|
||||
}
|
||||
|
@ -177,7 +173,6 @@ export function Pathaction(){
|
|||
|
||||
document.onmousedown = function(event){
|
||||
|
||||
console.log(event.button);
|
||||
|
||||
//辅助线段
|
||||
|
||||
|
@ -189,7 +184,6 @@ export function Pathaction(){
|
|||
|
||||
lineswitch = null;
|
||||
|
||||
console.log(linenew);
|
||||
|
||||
if(linenew){
|
||||
|
||||
|
@ -233,8 +227,6 @@ export function Pathaction(){
|
|||
for(let n=0;n<linenew.geometry.vertices.length;n++){
|
||||
jlmap3dedit.mapdata.sectionlist.sections.datalist[i].rail.push(linenew.geometry.vertices[n]);
|
||||
}
|
||||
console.log(jlmap3dedit.mapdata.sectionlist.sections.datalist[i]);
|
||||
console.log(jlmap3dedit.mapdata.sectionlist.sections.datalist[i].rail);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -289,7 +281,6 @@ export function Pathaction(){
|
|||
}
|
||||
//点击事件
|
||||
this.raycaster = function(data){
|
||||
console.log();
|
||||
if(scope.on == true){
|
||||
|
||||
//定义光线
|
||||
|
@ -300,13 +291,11 @@ export function Pathaction(){
|
|||
mouse.y = -(event.clientY / window.innerHeight) * 2 + 1;
|
||||
|
||||
raycaster.setFromCamera( mouse, data.camera );
|
||||
console.log(data.splineHelperObjects);
|
||||
let intersects1;
|
||||
|
||||
intersects1 = raycaster.intersectObjects( data.splineHelperObjects);
|
||||
|
||||
if(intersects1[0]){
|
||||
console.log(intersects1[0]);
|
||||
return intersects1[0].object;
|
||||
}
|
||||
|
||||
|
@ -329,9 +318,7 @@ export function Pathaction(){
|
|||
mouse.y = -(mousep.clientY / window.innerHeight) * 2 + 1;
|
||||
|
||||
raycaster.setFromCamera( mouse, jlmap3dedit.camera );
|
||||
console.log(jlmap3dedit.assetloader.modellist[3].mesh);
|
||||
var intersects = raycaster.intersectObjects(jlmap3dedit.assetloader.modellist[3].mesh.children);
|
||||
console.log(intersects);
|
||||
if(intersects[0]){
|
||||
resultpoint = intersects[0].point;
|
||||
return resultpoint;
|
||||
|
|
|
@ -79,13 +79,9 @@ export function Sectionaction(){
|
|||
|
||||
raycaster.setFromCamera( mouse, data.camera );
|
||||
let intersects1;
|
||||
// console.log(modellist);
|
||||
for(let i=0;i<modellist.length;i++){
|
||||
intersects1 = raycaster.intersectObject(modellist[i],true);
|
||||
// console.log(intersects1);
|
||||
if(intersects1[0]){
|
||||
// console.log(intersects1[0].object.code);
|
||||
// console.log(modellist[i].code);
|
||||
if(intersects1[0].object.code == modellist[i].code){
|
||||
|
||||
return modellist[i];
|
||||
|
@ -97,20 +93,17 @@ export function Sectionaction(){
|
|||
}
|
||||
|
||||
this.changemodel = function(jlmap3dedit,changedata){
|
||||
console.log(changedata);
|
||||
let scene = jlmap3dedit.scene;
|
||||
let assetloader = jlmap3dedit.assetloader;
|
||||
let isnewmodel = true;
|
||||
//判断是否是未加载模型
|
||||
for(let i=0;i<assetloader.modellist.length;i++){
|
||||
console.log(assetloader.modellist[i].assetUrl);
|
||||
|
||||
if(changedata.assetUrl == assetloader.modellist[i].assetUrl){
|
||||
isnewmodel = false;
|
||||
i = assetloader.modellist.length;
|
||||
}
|
||||
}
|
||||
console.log(isnewmodel);
|
||||
|
||||
jlmap3dedit.assetloader.loadnewsection(changedata,jlmap3dedit);
|
||||
|
||||
|
@ -118,25 +111,19 @@ export function Sectionaction(){
|
|||
|
||||
// for(let i=0;i<jlmap3dedit.mapdata.signallist.list.length;i++){
|
||||
// if(jlmap3dedit.selectmodel.code == jlmap3dedit.mapdata.signallist.list[i].mesh.code){
|
||||
// console.log("change");
|
||||
// let num = i;
|
||||
//
|
||||
// //判断是否修改模型
|
||||
// console.log(changedata.id );
|
||||
// console.log(jlmap3dedit.mapdata.signallist.list[i].mesh.name);
|
||||
// if(changedata.id != jlmap3dedit.mapdata.signallist.list[i].mesh.name){
|
||||
//
|
||||
// if(isnewmodel == true){
|
||||
// console.log("new");
|
||||
// return jlmap3dedit.assetloader.loadnewasset(jlmap3dedit,changedata,num);
|
||||
//
|
||||
// }else{
|
||||
// console.log("old");
|
||||
// return jlmap3dedit.assetloader.loadoldasset(jlmap3dedit,changedata,num);
|
||||
//
|
||||
// }
|
||||
// }else{
|
||||
// console.log("same");
|
||||
// return jlmap3dedit.selectmodel;
|
||||
// }
|
||||
//
|
||||
|
|
|
@ -55,8 +55,6 @@ export function Trainaction(){
|
|||
if(intersects1[0]){
|
||||
|
||||
if(intersects1[0].object.name == data.mapdata.trainlisttest.list[i].name){
|
||||
//console.log(intersects1[0].object.name);
|
||||
console.log(data.mapdata.trainlisttest.list[i]);
|
||||
return data.mapdata.trainlisttest.list[i];
|
||||
}
|
||||
}
|
||||
|
|
|
@ -43,12 +43,12 @@ export function jl3dEditorLoader(mapid,scope){
|
|||
|
||||
}
|
||||
}).catch(error => {
|
||||
console.log(error);
|
||||
console.error(error);
|
||||
});
|
||||
}
|
||||
|
||||
}).catch(error => {
|
||||
console.log(error);
|
||||
console.error(error);
|
||||
});
|
||||
|
||||
function initData(mapid,data3did){
|
||||
|
|
|
@ -29,7 +29,6 @@ import { jl3dEditorLoader } from '@/jlmap3d/edit/jl3dEditorLoader';
|
|||
import { Actionmanage } from '@/jlmap3d/edit/actionmanage';
|
||||
|
||||
export function JLmap3dEdit(dom, data, mapid) {
|
||||
console.log(data);
|
||||
|
||||
var scope = this;
|
||||
|
||||
|
@ -144,7 +143,6 @@ export function JLmap3dEdit(dom, data, mapid) {
|
|||
};
|
||||
|
||||
this.eventon = function(){
|
||||
//console.log("on");
|
||||
//raycaster交互模型点击事件
|
||||
document.getElementById("testdraw").addEventListener( "mousedown", onselect, false );
|
||||
//窗口自适应
|
||||
|
@ -154,7 +152,6 @@ export function JLmap3dEdit(dom, data, mapid) {
|
|||
};
|
||||
|
||||
this.eventoff = function(){
|
||||
//console.log("off");
|
||||
//raycaster交互模型点击事件
|
||||
document.getElementById("testdraw").removeEventListener( "mousedown", onselect, false );
|
||||
//窗口自适应
|
||||
|
@ -163,7 +160,6 @@ export function JLmap3dEdit(dom, data, mapid) {
|
|||
|
||||
this.exportsection = function(){
|
||||
let exporter = new THREE.OBJExporter();
|
||||
console.log(scope.mapdata);
|
||||
// let exportmodels = scope.mapdata.stationstandlist.group;
|
||||
let exportmodels = scope.mapdata.sectionlist.sectiongroup;
|
||||
// let exportmodels = scope.mapdata.stationstandlist.group;
|
||||
|
@ -184,7 +180,6 @@ export function JLmap3dEdit(dom, data, mapid) {
|
|||
|
||||
this.exportsection = function(){
|
||||
let exporter = new THREE.OBJExporter();
|
||||
console.log(scope.mapdata);
|
||||
// let exportmodels = scope.mapdata.stationstandlist.group;
|
||||
let exportSectionModel = scope.mapdata.sectionlist.sectiongroup;
|
||||
objDownload("section",exporter.parse( exportSectionModel ));
|
||||
|
@ -226,10 +221,6 @@ export function JLmap3dEdit(dom, data, mapid) {
|
|||
}
|
||||
|
||||
this.actiommode = function(changedata){
|
||||
console.log(changedata);
|
||||
console.log(scope.editmode);
|
||||
// console.log(scope.actionmode);
|
||||
// console.log(changedata);
|
||||
if(changedata == "trackreplace"){
|
||||
scope.editmode = "trackedit";
|
||||
scope.eventon();
|
||||
|
@ -274,7 +265,6 @@ export function JLmap3dEdit(dom, data, mapid) {
|
|||
// if(scope.editmode == "pathedit"){
|
||||
//
|
||||
// if(scope.actionmode == "drawrail"){
|
||||
// //console.log("drawrail");
|
||||
// scope.selectmodel = scope.action.pathaction.drawline(scope);
|
||||
// }
|
||||
//
|
||||
|
@ -305,27 +295,14 @@ export function JLmap3dEdit(dom, data, mapid) {
|
|||
for(let i=0,leni=scope.mapdata.stationstandlist.list.length;i<leni;i++){
|
||||
if(changeStation.code == scope.mapdata.stationstandlist.list[i].code){
|
||||
let changeData = scope.mapdata.stationstandlist.list[i];
|
||||
console.log(changeData);
|
||||
let topStandTrack = scope.mapdata.sectionlist.sections.datalist[changeData.stands[0].section];
|
||||
let downStandTrack = scope.mapdata.sectionlist.sections.datalist[changeData.stands[changeData.stands.length-1].section];
|
||||
|
||||
console.log(scope.mapdata.sectionlist.sections);
|
||||
console.log(topStandTrack.mesh.railpoint[0].x);
|
||||
console.log(topStandTrack.mesh.railpoint[2].x);
|
||||
console.log(downStandTrack.mesh.railpoint[0].x);
|
||||
console.log(downStandTrack.mesh.railpoint[2].x);
|
||||
|
||||
let rightpos = topStandTrack.leftStopPercent*(topStandTrack.mesh.railpoint[2].x -topStandTrack.mesh.railpoint[0].x)+topStandTrack.mesh.railpoint[0].x;
|
||||
let leftpos = downStandTrack.rightStopPercent*(downStandTrack.mesh.railpoint[2].x -downStandTrack.mesh.railpoint[0].x)+downStandTrack.mesh.railpoint[0].x;
|
||||
|
||||
let rightX = changeData.mesh.position.x-63.4 - rightpos;
|
||||
let leftX = changeData.mesh.position.x+63.4 - leftpos;
|
||||
console.log("----------------------------");
|
||||
console.log(rightpos);
|
||||
console.log(leftpos);
|
||||
console.log("----------------------------");
|
||||
console.log(rightX);
|
||||
console.log(leftX);
|
||||
topStandTrack.mesh.position.x = topStandTrack.mesh.position.z + rightX;
|
||||
downStandTrack.mesh.position.x = downStandTrack.mesh.position.x + leftX;
|
||||
//
|
||||
|
@ -367,9 +344,6 @@ export function JLmap3dEdit(dom, data, mapid) {
|
|||
plane2.rotation.y = Math.PI/2;
|
||||
let leftpos = scope.mapdata.sectionlist.sections.datalist[k].leftStopPercent*(scope.mapdata.sectionlist.sections.datalist[k].railpoint[2].x -scope.mapdata.sectionlist.sections.datalist[k].railpoint[0].x)+scope.mapdata.sectionlist.sections.datalist[k].railpoint[0].x;
|
||||
let rightpos = scope.mapdata.sectionlist.sections.datalist[k].rightStopPercent*(scope.mapdata.sectionlist.sections.datalist[k].railpoint[2].x -scope.mapdata.sectionlist.sections.datalist[k].railpoint[0].x)+scope.mapdata.sectionlist.sections.datalist[k].railpoint[0].x;
|
||||
// console.log("==========");
|
||||
// console.log(scope.mapdata.sectionlist.sections.datalist[k].leftStopPercent);
|
||||
// console.log(scope.mapdata.sectionlist.sections.datalist[k].rightStopPercent);
|
||||
plane1.position.set(leftpos,scope.mapdata.sectionlist.sections.datalist[k].railpoint[1].y,scope.mapdata.sectionlist.sections.datalist[k].railpoint[1].z);
|
||||
plane2.position.set(rightpos,scope.mapdata.sectionlist.sections.datalist[k].railpoint[1].y,scope.mapdata.sectionlist.sections.datalist[k].railpoint[1].z);
|
||||
stationStopGroup.add(plane1);
|
||||
|
@ -393,8 +367,6 @@ export function JLmap3dEdit(dom, data, mapid) {
|
|||
|
||||
//自动匹配轨道信号灯道岔
|
||||
this.autoss = function(){
|
||||
console.log("autoss");
|
||||
// console.log(scope.mapdata);
|
||||
scope.mapdata.signallist.resetsignal(scope.mapdata);
|
||||
scope.mapdata.switchlist.resetswitch(scope.mapdata);
|
||||
//old
|
||||
|
@ -494,8 +466,6 @@ export function JLmap3dEdit(dom, data, mapid) {
|
|||
newpointlist.push(new THREE.Vector3(alignmentModel.railpoint[1].x,alignmentModel.railpoint[0].y,alignmentModel.railpoint[0].z+0.001));
|
||||
newpointlist.push(new THREE.Vector3(alignmentModel.railpoint[2].x,alignmentModel.railpoint[0].y,alignmentModel.railpoint[0].z));
|
||||
|
||||
// console.log(oldobject);
|
||||
|
||||
let newSection = reCreatSection(newpointlist,oldobject);
|
||||
newSection.meshtype = "section";
|
||||
scope.mapdata.sectionlist.sections.datalist[alignmentCode].mesh = newSection;
|
||||
|
@ -569,8 +539,6 @@ export function JLmap3dEdit(dom, data, mapid) {
|
|||
|
||||
//三维交互点击事件函数
|
||||
function onselect(event) {
|
||||
//console.log("select");
|
||||
//console.log("select");
|
||||
if(scope.selectswitch == true){
|
||||
|
||||
scope.transcontrol.detach();
|
||||
|
@ -593,7 +561,6 @@ export function JLmap3dEdit(dom, data, mapid) {
|
|||
}
|
||||
|
||||
if(scope.editmode == "stationedit"){
|
||||
console.log("stat!!!!!!!!!!!!");
|
||||
scope.selectmodel = scope.action.stationaction.raycaster(scope);
|
||||
}
|
||||
|
||||
|
@ -607,11 +574,9 @@ export function JLmap3dEdit(dom, data, mapid) {
|
|||
|
||||
if(scope.editmode == "pathedit"){
|
||||
scope.selectmodel = scope.action.pathaction.raycaster(scope);
|
||||
//console.log(scope.selectmodel);
|
||||
}
|
||||
|
||||
if(scope.selectmodel != null){
|
||||
//console.log(scope.selectmodel.rotation);
|
||||
if(scalControls.scalon){
|
||||
|
||||
}else{
|
||||
|
|
|
@ -36,7 +36,6 @@ export function SectionList() {
|
|||
if(sectiondata[i].type == "01" || sectiondata[i].type == "03"){
|
||||
//初始化区段对象数据
|
||||
let newsection = new SectionModel(sectiondata[i]);
|
||||
// console.log(sectiondata[i]);
|
||||
newsection.name = sectiondata[i].name;
|
||||
newsection.code = sectiondata[i].code;
|
||||
newsection.index = i;
|
||||
|
@ -49,7 +48,6 @@ export function SectionList() {
|
|||
newsection.points = sectiondata[i].points;
|
||||
newsection.pointslength = sectiondata[i].points.length-1;
|
||||
newsection.railpoint = [];
|
||||
// console.log(sectiondata[i].points.length);
|
||||
newsection.standTrack = sectiondata[i].standTrack;
|
||||
|
||||
newsection.endbuild = false;
|
||||
|
@ -97,7 +95,6 @@ export function SectionList() {
|
|||
let acode = switchdata[i].sectionACode;
|
||||
let bcode = switchdata[i].sectionBCode;
|
||||
let ccode = switchdata[i].sectionCCode;
|
||||
// console.log(switchdata[i]);
|
||||
|
||||
|
||||
let aposx = (scope.sections.datalist[acode].points[0].x + scope.sections.datalist[acode].points[scope.sections.datalist[acode].pointslength].x)/2;
|
||||
|
@ -106,7 +103,6 @@ export function SectionList() {
|
|||
let aposy = (scope.sections.datalist[acode].points[0].y + scope.sections.datalist[acode].points[scope.sections.datalist[acode].pointslength].y)/2;
|
||||
let cposy = (scope.sections.datalist[ccode].points[0].y + scope.sections.datalist[ccode].points[scope.sections.datalist[ccode].pointslength].y)/2;
|
||||
|
||||
// console.log("----------------");
|
||||
if(aposx > cposx){
|
||||
if(aposy < cposy){
|
||||
// ——A
|
||||
|
@ -175,7 +171,6 @@ export function SectionList() {
|
|||
reals:[],
|
||||
posx:null,
|
||||
};
|
||||
// console.log(stationlist[i]);
|
||||
|
||||
// realstopsection.stands.push();
|
||||
for(let n=0,lenn = stationlist[i].stands.length;n<lenn;n++){
|
||||
|
@ -384,7 +379,6 @@ export function SectionList() {
|
|||
}
|
||||
//根据站台区段创建站台位置 120停车点距离
|
||||
for(let j=0,lenj=stations.length;j<lenj;j++){
|
||||
// console.log(j);
|
||||
let direction1 = scope.sections.datalist[stations[j].stands[0].section];
|
||||
let direction2 = scope.sections.datalist[stations[j].stands[1].section];
|
||||
|
||||
|
@ -404,7 +398,6 @@ export function SectionList() {
|
|||
}
|
||||
|
||||
// scope.sections.datalist[stations[0].stands[0].section].endbuild = true;
|
||||
console.log("START BUILD !!!!!!!!!!!!!!!!!");
|
||||
buildsectionall(scope.sections.datalist[stations[0].stands[0].section]);
|
||||
resolve("loadersection");
|
||||
});
|
||||
|
@ -492,12 +485,7 @@ export function SectionList() {
|
|||
y:0,
|
||||
z:position.z
|
||||
};
|
||||
// console.log(origin+"******************************");
|
||||
// console.log(start);
|
||||
// console.log(origin);
|
||||
if(scope.sections.datalist[start].standTrack == true && start != origin){
|
||||
// console.log(start+"到达");
|
||||
// console.log("++++++++++++++++++++++++");
|
||||
return ;
|
||||
}else if(scope.sections.datalist[start].rsection == undefined){
|
||||
return ;
|
||||
|
@ -666,11 +654,7 @@ export function SectionList() {
|
|||
];
|
||||
}
|
||||
|
||||
// console.log(data.ctype);
|
||||
if(type == "cross"){
|
||||
// console.log(data.ctype);
|
||||
// console.log(scope.sections.datalist[data.code].points.length);
|
||||
// console.log(scope.sections.datalist[data.code]);
|
||||
if(data.ctype == "1"||data.ctype == "2" ){
|
||||
|
||||
|
||||
|
@ -1015,16 +999,13 @@ export function SectionList() {
|
|||
let acode = switch2d[i].sectionACode;
|
||||
let bcode = switch2d[i].sectionBCode;
|
||||
let ccode = switch2d[i].sectionCCode;
|
||||
// console.log(switchdata[i]);
|
||||
|
||||
// console.log(scope.sections.datalist[acode]);
|
||||
let aposx = (scope.sections.datalist[acode].points[0].x + scope.sections.datalist[acode].points[scope.sections.datalist[acode].pointslength].x)/2;
|
||||
let cposx = (scope.sections.datalist[ccode].points[0].x + scope.sections.datalist[ccode].points[scope.sections.datalist[ccode].pointslength].x)/2;
|
||||
|
||||
let aposy = (scope.sections.datalist[acode].points[0].y + scope.sections.datalist[acode].points[scope.sections.datalist[acode].pointslength].y)/2;
|
||||
let cposy = (scope.sections.datalist[ccode].points[0].y + scope.sections.datalist[ccode].points[scope.sections.datalist[ccode].pointslength].y)/2;
|
||||
|
||||
// console.log("----------------");
|
||||
if(aposx > cposx){
|
||||
if(aposy < cposy){
|
||||
// ——A
|
||||
|
|
|
@ -83,18 +83,14 @@ export function StationStandList() {
|
|||
}
|
||||
|
||||
}
|
||||
console.log(scope.list);
|
||||
resolve("loadedstation");
|
||||
});
|
||||
}
|
||||
this.loadpromise = function(jlmap3ddata,standsdata,jlmapdata,scene,assetloader,otherStation){
|
||||
return new Promise(function(resolve, reject){
|
||||
// console.log(jlmap3ddata);
|
||||
let jlmapstationdata = jlmapdata.stationList;
|
||||
let jlmapstanddata = jlmapdata.stationStandList;
|
||||
// jlmapstationdata.splice(0,1);
|
||||
console.log(standsdata);
|
||||
console.log(jlmapstationdata);
|
||||
// for(let i=0;i<jlmapstationdata.length;i++){// || jlmapstationdata[i].subheadDisplay == false
|
||||
// if(jlmapstationdata[i].visible == false){
|
||||
// jlmapstationdata.splice(i,1);
|
||||
|
@ -103,30 +99,19 @@ export function StationStandList() {
|
|||
// standsdata[i].code = jlmapstationdata[i].code;
|
||||
// standsdata[i].name = jlmapstationdata[i].name;
|
||||
// }
|
||||
// // console.log(jlmapstationdata[i].subheadDisplay);
|
||||
// }
|
||||
|
||||
// console.log(jlmapstationdata);
|
||||
console.log(standsdata);
|
||||
//
|
||||
// console.log(jlmapstationdata);
|
||||
//
|
||||
// console.log(standsdata);
|
||||
// console.log(jlmapstationdata);
|
||||
for(let i=0;i<jlmapstationdata.length;i++){
|
||||
if(jlmapstationdata[i].visible == false || jlmapstationdata[i].depot == true){
|
||||
jlmapstationdata.splice(i,1);
|
||||
i--;
|
||||
}else{
|
||||
// console.log(jlmapstationdata[i]);
|
||||
// console.log(standsdata[i]);
|
||||
standsdata[i].code = jlmapstationdata[i].code;
|
||||
standsdata[i].name = jlmapstationdata[i].name;
|
||||
}
|
||||
}
|
||||
// console.log(otherStation);
|
||||
// console.log(standsdata);
|
||||
// console.log(assetloader.modellist);
|
||||
let stations = jlmap3ddata.stationstandlist.list;
|
||||
let num;
|
||||
let num2;
|
||||
|
@ -154,9 +139,6 @@ export function StationStandList() {
|
|||
num3 = j;
|
||||
}
|
||||
}
|
||||
// console.log("+++++++++++++");
|
||||
// console.log(jlmapstanddata);
|
||||
// console.log(standsdata);
|
||||
for(let i=0;i<standsdata.length;i++){
|
||||
let newstationstand = new StationStandModel(standsdata[i]);
|
||||
let newstationmesh;
|
||||
|
@ -186,7 +168,6 @@ export function StationStandList() {
|
|||
newstationstand.name = standsdata[i].name;
|
||||
newstationstand.inside = standsdata[i].inside;
|
||||
|
||||
// console.log(standsdata[i]);
|
||||
newstationmesh.code = standsdata[i].code;
|
||||
newstationmesh.name = standsdata[i].name;
|
||||
newstationmesh.meshtype = "station";
|
||||
|
@ -211,13 +192,11 @@ export function StationStandList() {
|
|||
}else{
|
||||
newstationmesh = assetloader.modellist[num2].mesh.clone(true);
|
||||
}
|
||||
// console.log(jlmapstanddata[j]);
|
||||
|
||||
newstationstand.code = standsdata[i].code;
|
||||
newstationstand.name = standsdata[i].name;
|
||||
newstationstand.inside = standsdata[i].inside;
|
||||
|
||||
// console.log(standsdata[i]);
|
||||
newstationmesh.code = standsdata[i].code;
|
||||
newstationmesh.name = standsdata[i].name;
|
||||
newstationmesh.meshtype = "station";
|
||||
|
@ -232,11 +211,9 @@ export function StationStandList() {
|
|||
scope.list.push(newstationstand);
|
||||
}else{
|
||||
newstationmesh = assetloader.modellist[num3].mesh.clone(true);
|
||||
// console.log(jlmapstanddata[j]);
|
||||
newstationstand.code = standsdata[i].code;
|
||||
newstationstand.name = standsdata[i].name;
|
||||
newstationstand.inside = standsdata[i].inside;
|
||||
// console.log(standsdata[i]);
|
||||
newstationmesh.code = standsdata[i].code;
|
||||
newstationmesh.name = standsdata[i].name;
|
||||
newstationmesh.position.x = standsdata[i].position.x;
|
||||
|
|
|
@ -14,11 +14,9 @@ export function SwitchList() {
|
|||
};
|
||||
|
||||
this.initpromise = function(jlmap3ddata,data,scene,assetloader,netdata){
|
||||
// console.log(jlmap3ddata);
|
||||
return new Promise(function(resolve, reject){
|
||||
scene.add( scope.switchgroup );
|
||||
let sectiondata = jlmap3ddata.sectionlist.sections.datalist;
|
||||
// console.log(sectiondata);
|
||||
let num;
|
||||
for(let j=0;j<assetloader.modellist.length;j++){
|
||||
if(assetloader.modellist[j].deviceType == "autoswitch"){
|
||||
|
@ -58,7 +56,6 @@ export function SwitchList() {
|
|||
return new Promise(function(resolve, reject){
|
||||
scene.add( scope.switchgroup );
|
||||
// let sectiondata = jlmap3ddata.sectionlist.sections.datalist;
|
||||
// console.log(sectiondata);
|
||||
let num;
|
||||
for(let j=0;j<assetloader.modellist.length;j++){
|
||||
if(assetloader.modellist[j].type == "switch"){
|
||||
|
@ -70,7 +67,6 @@ export function SwitchList() {
|
|||
}
|
||||
};
|
||||
for(let i=0,leni = switchdata.length;i<leni;i++){
|
||||
// console.log(switchdata[i]);
|
||||
let newswitch = {
|
||||
code:switchdata[i].code,
|
||||
name:switchdata[i].name,
|
||||
|
@ -79,7 +75,6 @@ export function SwitchList() {
|
|||
pc:switchdata[i].pc
|
||||
};
|
||||
|
||||
// console.log(newswitch.pa);
|
||||
let autoswitch = assetloader.modellist[num].mesh.clone(true);
|
||||
autoswitch.code = switchdata[i].code;
|
||||
for(let j=0;j<autoswitch.children.length;j++){
|
||||
|
@ -101,7 +96,6 @@ export function SwitchList() {
|
|||
}
|
||||
|
||||
this.resetswitch = function(data){
|
||||
// console.log("reset");
|
||||
let sectiondata = data.sectionlist.sectiongroup;
|
||||
for(let i=0;i<scope.switchs.datalist.length;i++){
|
||||
|
||||
|
|
|
@ -485,7 +485,6 @@ export function Moveanimate(main){
|
|||
}
|
||||
|
||||
}else{
|
||||
// console.log(scope.animatelist[k].connectmodel);
|
||||
if(scope.nowmodelname != scope.playlist[scope.playorder][i].connectmodel.name){
|
||||
scope.nowmodelname = scope.playlist[scope.playorder][i].connectmodel.name;
|
||||
main.animationmsgshowon(scope.playlist[scope.playorder][i].connectmodel);
|
||||
|
|
|
@ -10,7 +10,6 @@ export function Textconfig(){
|
|||
if(scope.devicelist.length>0){
|
||||
scope.devicelist = [];
|
||||
}
|
||||
console.log(selectmodel.deviceType);
|
||||
if(selectmodel.deviceType == "DeviceSwitch"){
|
||||
initSwitchText(selectmodel);
|
||||
}
|
||||
|
@ -92,9 +91,6 @@ export function Textconfig(){
|
|||
}
|
||||
|
||||
|
||||
// if(part.text == null){
|
||||
// console.log(selectmodel.children[i].name);
|
||||
// }
|
||||
if(part.text){
|
||||
scope.devicelist.push(part);
|
||||
}
|
||||
|
@ -192,9 +188,6 @@ export function Textconfig(){
|
|||
part.msg = "用于机内外电缆连接,方便更换转辙机。";
|
||||
selectmodel.children[i].text = "二十位插接件";
|
||||
}
|
||||
// if(part.text == null){
|
||||
// console.log(selectmodel.children[i].name);
|
||||
// }
|
||||
if(part.text){
|
||||
scope.devicelist.push(part);
|
||||
}
|
||||
|
|
|
@ -143,11 +143,8 @@ export function Jl3ddeviceNew(dom,group,token,skinCode) {
|
|||
stationList.push(mapnetdata.stationList[i]);
|
||||
}
|
||||
}
|
||||
// console.log(mapnetdata.stationList);
|
||||
for(let k in psdVoiceStationList){
|
||||
for(let i=0,leni=stationList.length;i<leni;i++){
|
||||
// console.log("---------------");
|
||||
// console.log("---------------");
|
||||
if(psdVoiceStationList[k].stationCode == stationList[i].code){
|
||||
psdVoiceStationList[k].nowStationName = stationList[i].name;
|
||||
|
||||
|
@ -294,7 +291,6 @@ export function Jl3ddeviceNew(dom,group,token,skinCode) {
|
|||
for (let i = 0; i < scope.mixers.length; i++) {
|
||||
if (scope.mixers[i]) {
|
||||
if( scope.mixers[i].staticType){
|
||||
// console.log(scope.mixers[i].time);
|
||||
if(scope.mixers[i]._actions[0].time<stopTime){
|
||||
scope.mixers[i].update(delta);
|
||||
}else{
|
||||
|
@ -343,11 +339,7 @@ export function Jl3ddeviceNew(dom,group,token,skinCode) {
|
|||
scope.raycasterstatus = false;
|
||||
scope.nowobject = null;
|
||||
updatemenulist();
|
||||
if(data._type == "Station"){
|
||||
|
||||
console.log(data);
|
||||
}
|
||||
|
||||
if (data._type == "Switch") {
|
||||
// scope.modelmanager.switchmodel.locateType = data.body.locateType;
|
||||
scope.modelmanager.switchmodel.code = data.code;
|
||||
|
@ -493,8 +485,6 @@ export function Jl3ddeviceNew(dom,group,token,skinCode) {
|
|||
this.changeAnimate = function(type){
|
||||
//
|
||||
|
||||
console.log(type);
|
||||
// console.log(scope.modelmanager.staticswitchmodel);
|
||||
|
||||
// scope.modelmanager.staticswitchmodel.action["2kai"].reset();
|
||||
// scope.modelmanager.staticswitchmodel.action["5jiasuo"].reset();
|
||||
|
@ -520,7 +510,6 @@ export function Jl3ddeviceNew(dom,group,token,skinCode) {
|
|||
stopTime = 3.33;
|
||||
scope.modelmanager.staticswitchmodel.action.play();
|
||||
|
||||
console.log(scope.mixers);
|
||||
}
|
||||
if(type == "action2"){
|
||||
scope.camera.position.x = -7.23;
|
||||
|
@ -584,8 +573,6 @@ export function Jl3ddeviceNew(dom,group,token,skinCode) {
|
|||
scope.camera.position.y = 22.56;
|
||||
scope.camera.position.z = -1.348;
|
||||
scope.controls.target = new THREE.Vector3(-2.15,10,-1.348);
|
||||
// console.log(scope.camera.position);
|
||||
// console.log(scope.controls.target);
|
||||
scope.modelmanager.staticswitchmodel.action.reset();
|
||||
scope.modelmanager.staticswitchmodel.action.time = 23.36;
|
||||
stopTime = 26.66;
|
||||
|
|
|
@ -93,7 +93,6 @@ export function ModelManager(){
|
|||
Promise.all(initlist).then((result) => {
|
||||
resolve("success"); //['成功了', 'success']
|
||||
}).catch((error) => {
|
||||
//console.log(error);
|
||||
});
|
||||
|
||||
});
|
||||
|
|
|
@ -156,7 +156,6 @@ export function JLmapDriving(dom,data,mapId,storemod,translation,routegroup,proj
|
|||
getPublishMapDetail(mapId).then(data => {
|
||||
let mapnetdata = data.data;
|
||||
getPublish3dMapDetail(mapId).then(netdata => {
|
||||
// console.log(netdata);
|
||||
let assetsdata = JSON.parse(netdata.data.sections);
|
||||
|
||||
scope.datatype = "new";
|
||||
|
@ -271,7 +270,6 @@ export function JLmapDriving(dom,data,mapId,storemod,translation,routegroup,proj
|
|||
};
|
||||
|
||||
updatemmi.updatedrivingcode = function(code) {
|
||||
// console.log(trainlisttest);
|
||||
drivingcode = code;
|
||||
trainlisttest.group.children[0].children[0].add(controls3.getObject());
|
||||
controls3.getObject().position.x = 10;
|
||||
|
@ -313,7 +311,6 @@ export function JLmapDriving(dom,data,mapId,storemod,translation,routegroup,proj
|
|||
if(driverWebWorker){
|
||||
driverWebWorker.terminate();
|
||||
}
|
||||
// console.log(scope);
|
||||
// scope = null;
|
||||
};
|
||||
|
||||
|
@ -386,7 +383,6 @@ export function JLmapDriving(dom,data,mapId,storemod,translation,routegroup,proj
|
|||
realsectionlist = loadrealsectionlist;
|
||||
rails = loadrails;
|
||||
|
||||
console.log(trainlisttest);
|
||||
trainlisttest.group.children[0].getObjectByName("C6").add(cameracctv);
|
||||
}
|
||||
|
||||
|
@ -401,7 +397,6 @@ export function JLmapDriving(dom,data,mapId,storemod,translation,routegroup,proj
|
|||
};
|
||||
|
||||
this.eventoff = function() {
|
||||
// console.log("off");
|
||||
// raycaster交互模型点击事件
|
||||
document.getElementById('jlsimulation').removeEventListener( 'mousedown', onselect, false );
|
||||
// 窗口自适应
|
||||
|
@ -420,7 +415,6 @@ export function JLmapDriving(dom,data,mapId,storemod,translation,routegroup,proj
|
|||
camera.position.z = mesh.children[0].position.z;
|
||||
// controls.target = new THREE.Vector3(mesh.position.x,0,mesh.children[0].position.z);
|
||||
}
|
||||
// console.log(mesh);
|
||||
if (type == 'station') {
|
||||
camera.position.x = mesh.position.x;
|
||||
camera.position.y = mesh.position.y+800;
|
||||
|
@ -493,7 +487,6 @@ export function JLmapDriving(dom,data,mapId,storemod,translation,routegroup,proj
|
|||
}
|
||||
|
||||
if (scope.raycasterswitch == 'section') {
|
||||
// console.log(sectionlist.sections.modellist);
|
||||
let intersects = raycaster.intersectObjects( sectionlist.sections.modellist, true);
|
||||
if (intersects[0]) {
|
||||
|
||||
|
|
|
@ -81,7 +81,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
}
|
||||
|
||||
if(data.type == "DeviceCtrl_3D"){
|
||||
// console.log(data);
|
||||
if (data.body.type== 'SIGNAL' && signallist) {
|
||||
signalupdate(data.body);
|
||||
return;
|
||||
|
@ -201,8 +200,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
|
||||
}
|
||||
this.updatamap = function(newsectionlist,newlinklist,newsignallist,newstationstandlist,newtrainlisttest,newrealsectionlist,newrails,newtdt, materiallist, nowaction, scene) {
|
||||
// console.log(mapdata);
|
||||
// console.log(newtrainlisttest);
|
||||
trainmodel = newtrainlisttest.group.children[0];
|
||||
trainlisttest = newtrainlisttest;
|
||||
sectionlist = newsectionlist;
|
||||
|
@ -222,7 +219,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
|
||||
this.socketon = function(topic) {
|
||||
try {
|
||||
// console.log("teststomp");
|
||||
// scope.teststomp.subscribe(topic, callback, header);
|
||||
} catch (error) {
|
||||
console.error('websocket订阅失败');
|
||||
|
@ -255,13 +251,11 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
|
||||
// 仿真socket接口回调函数
|
||||
function callback(Response) {
|
||||
// console.log(Response);
|
||||
// 对象化数据
|
||||
|
||||
let data = JSON.parse(Response.body);
|
||||
// stats.update();
|
||||
// 遍历后台数据
|
||||
// console.log(data);
|
||||
|
||||
if(data.type == "Train_Position"){
|
||||
nowTrainRun(data.body);
|
||||
|
@ -306,7 +300,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
}
|
||||
|
||||
function DeviceDestroy(data){
|
||||
// console.log(data);
|
||||
for(let i=0,leni=data.length;i<leni;i++){
|
||||
|
||||
if(data[i].type == "SIGNAL"){
|
||||
|
@ -359,10 +352,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
}
|
||||
|
||||
function otherTrainUpdate(data,updateTrainModel){
|
||||
// console.log(data);
|
||||
// if(data.code = "336"){
|
||||
// console.log(data);
|
||||
// }
|
||||
if(rails.sectionrail[data.section]){
|
||||
if(data.section != updateTrainModel.nowsection){
|
||||
updateTrainModel.nowsection = data.section;
|
||||
|
@ -418,7 +407,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
// if(updateTrainModel.children[1].rotalist.length > 0 || updateTrainModel.children[2].rotalist.length > 0 || updateTrainModel.children[3].rotalist.length > 0 || updateTrainModel.children[4].rotalist.length > 0|| updateTrainModel.children[5].rotalist.length > 0){
|
||||
|
||||
for(let rs = 1;rs<updateTrainModel.children.length;rs++){
|
||||
//console.log(rs);
|
||||
if(updateTrainModel.children[rs].rotalist[0]){
|
||||
|
||||
let offsetz = parseFloat(updateTrainModel.children[rs].rotalist[0].posr.z) + parseFloat(updateTrainModel.children[rs].position.z);
|
||||
|
@ -441,13 +429,11 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
xh = updateTrainModel.children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainmodel.children[rs].rotalist.length);
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
// console.log(trainmodel.rotalist);
|
||||
// }
|
||||
|
||||
}else{
|
||||
|
@ -493,7 +479,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
|
||||
// if(updateTrainModel.children[1].rotalist.length > 0 || updateTrainModel.children[2].rotalist.length > 0 || updateTrainModel.children[3].rotalist.length > 0 || updateTrainModel.children[4].rotalist.length > 0|| updateTrainModel.children[5].rotalist.length > 0){
|
||||
for(let rs = 1;rs<updateTrainModel.children.length;rs++){
|
||||
//console.log(rs);
|
||||
if(updateTrainModel.children[rs].rotalist[0]){
|
||||
let offsetz = parseFloat(updateTrainModel.children[rs].rotalist[0].posr.z) - parseFloat(updateTrainModel.children[rs].matrixWorld.elements[14]);
|
||||
|
||||
|
@ -658,7 +643,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
if(trainmodel.children[1].rotalist.length > 0 || trainmodel.children[2].rotalist.length > 0 || trainmodel.children[3].rotalist.length > 0 || trainmodel.children[4].rotalist.length > 0|| trainmodel.children[5].rotalist.length > 0){
|
||||
|
||||
for(let rs = 1;rs<trainmodel.children.length;rs++){
|
||||
//console.log(rs);
|
||||
if(trainmodel.children[rs].rotalist[0]){
|
||||
|
||||
let offsetz = parseFloat(trainmodel.children[rs].rotalist[0].posr.z) + parseFloat(trainmodel.children[rs].position.z);
|
||||
|
@ -685,13 +669,10 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
xh = trainmodel.children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainmodel.children[rs].rotalist.length);
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
// console.log(trainmodel.rotalist);
|
||||
}
|
||||
|
||||
}else{
|
||||
|
@ -768,7 +749,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
|
||||
if(trainmodel.children[1].rotalist.length > 0 || trainmodel.children[2].rotalist.length > 0 || trainmodel.children[3].rotalist.length > 0 || trainmodel.children[4].rotalist.length > 0|| trainmodel.children[5].rotalist.length > 0){
|
||||
for(let rs = 1;rs<trainmodel.children.length;rs++){
|
||||
//console.log(rs);
|
||||
if(trainmodel.children[rs].rotalist[0]){
|
||||
let offsetz = parseFloat(trainmodel.children[rs].rotalist[0].posr.z) - parseFloat(trainmodel.children[rs].matrixWorld.elements[14]);
|
||||
trainmodel.children[rs].position.z += offsetz;
|
||||
|
@ -794,7 +774,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
xh = trainmodel.children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainmodel.children[rs].rotalist.length);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -817,10 +796,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
|||
|
||||
|
||||
function traindoorupdate(data){
|
||||
// console.log(data);
|
||||
// console.log("direct:"+trainmodel.right);
|
||||
// console.log(trainmodel.openleft);
|
||||
// console.log(trainmodel.openright);
|
||||
if(trainmodel.code == data.trainCode){
|
||||
if(trainmodel.right == "0"){
|
||||
if(data.code == "2"){
|
||||
|
|
|
@ -4,11 +4,9 @@ export function UpdateTrain(camera,traindata,control){
|
|||
if(traindata != undefined && traindata.group.children[0]){//traindata.group.children[0].dispose == false
|
||||
|
||||
if(traindata.group.children[0].progress != null){
|
||||
// console.log(traindata.group);
|
||||
let trainmodel = traindata.group.children[0];
|
||||
if(trainmodel.speeds > 0 && trainmodel.speeds){
|
||||
let speed = null;
|
||||
// console.log(traindata.group.children[0].progress);
|
||||
if(traindata.group.children[0].progress >=0&&traindata.group.children[0].progress<=1){
|
||||
|
||||
let movecurve = trainmodel.curve;
|
||||
|
@ -44,7 +42,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
|
||||
if(trainmodel.children[1].rotalist.length > 0 || trainmodel.children[2].rotalist.length > 0 || trainmodel.children[3].rotalist.length > 0 || trainmodel.children[4].rotalist.length > 0|| trainmodel.children[5].rotalist.length > 0){
|
||||
for(let rs = 1;rs<6;rs++){
|
||||
//console.log(rs);
|
||||
if(trainmodel.children[rs].rotalist[0]){
|
||||
let offsetz = parseFloat(trainmodel.children[rs].matrixWorld.elements[14]) - parseFloat(trainmodel.children[rs].rotalist[0].posr.z);
|
||||
|
||||
|
@ -66,7 +63,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
xh = trainmodel.children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainmodel.children[rs].rotalist.length);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -103,7 +99,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
if(trainmodel.children[1].rotalist.length > 0 || trainmodel.children[2].rotalist.length > 0 || trainmodel.children[3].rotalist.length > 0 || trainmodel.children[4].rotalist.length > 0|| trainmodel.children[5].rotalist.length > 0){
|
||||
|
||||
for(let rs = 1;rs<6;rs++){
|
||||
//console.log(rs);
|
||||
if(trainmodel.children[rs].rotalist[0]){
|
||||
|
||||
let offsetz = parseFloat(trainmodel.children[rs].rotalist[0].posr.z) - parseFloat(trainmodel.children[rs].matrixWorld.elements[14]);
|
||||
|
@ -126,13 +121,10 @@ export function UpdateTrain(camera,traindata,control){
|
|||
xh = trainmodel.children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainmodel.children[rs].rotalist.length);
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
// console.log(trainmodel.rotalist);
|
||||
}
|
||||
trainmodel.progress += trainmodel.speeds;
|
||||
}
|
||||
|
@ -152,9 +144,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
trainmodel.nextcode = null;
|
||||
}
|
||||
|
||||
// console.log(trainmodel.name);
|
||||
// console.log(trainmodel.progress);
|
||||
// console.log(trainmodel.nextcurve);
|
||||
// if(trainmodel.status == "02"){
|
||||
// trainmodel.progress = 0;
|
||||
// }else if(trainmodel.status == "03"){
|
||||
|
@ -197,7 +186,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
|
||||
if(trainmodel.children[1].rotalist.length > 0 || trainmodel.children[2].rotalist.length > 0 || trainmodel.children[3].rotalist.length > 0 || trainmodel.children[4].rotalist.length > 0|| trainmodel.children[5].rotalist.length > 0){
|
||||
for(let rs = 1;rs<6;rs++){
|
||||
//console.log(rs);
|
||||
if(trainmodel.children[rs].rotalist[0]){
|
||||
let offsetz = parseFloat(trainmodel.children[rs].matrixWorld.elements[14]) - parseFloat(trainmodel.children[rs].rotalist[0].posr.z);
|
||||
|
||||
|
@ -219,7 +207,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
xh = trainmodel.children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainmodel.children[rs].rotalist.length);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -256,7 +243,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
if(trainmodel.children[1].rotalist.length > 0 || trainmodel.children[2].rotalist.length > 0 || trainmodel.children[3].rotalist.length > 0 || trainmodel.children[4].rotalist.length > 0|| trainmodel.children[5].rotalist.length > 0){
|
||||
|
||||
for(let rs = 1;rs<6;rs++){
|
||||
//console.log(rs);
|
||||
if(trainmodel.children[rs].rotalist[0]){
|
||||
|
||||
let offsetz = parseFloat(trainmodel.children[rs].rotalist[0].posr.z) - parseFloat(trainmodel.children[rs].matrixWorld.elements[14]);
|
||||
|
@ -279,16 +265,12 @@ export function UpdateTrain(camera,traindata,control){
|
|||
xh = trainmodel.children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainmodel.children[rs].rotalist.length);
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
// console.log(trainmodel.rotalist);
|
||||
}
|
||||
|
||||
// console.log(trainmodel.nextcurve);
|
||||
if(trainmodel.progress > -(trainmodel.speeds)){
|
||||
trainmodel.progress += trainmodel.speeds;
|
||||
}
|
||||
|
|
|
@ -106,7 +106,6 @@ export function Jl3dfaultdevice(dom,group,token,skinCode) {
|
|||
let topic = '/user/queue/simulation/'+ group +'/jl3d';
|
||||
let header = {'X-Token': token};
|
||||
try {
|
||||
// console.log("teststomp");
|
||||
teststomp.subscribe(topic, callback, header);
|
||||
} catch (error) {
|
||||
console.error('websocket订阅失败');
|
||||
|
@ -120,7 +119,6 @@ export function Jl3dfaultdevice(dom,group,token,skinCode) {
|
|||
// scope.selectmodel(data);
|
||||
// }else{
|
||||
if(data.type == "DeviceCtrl_3D"){
|
||||
// console.log(data.body);
|
||||
if(data.body.code == scope.nowcode){
|
||||
scope.updateaction(data.body);
|
||||
}
|
||||
|
@ -143,7 +141,6 @@ export function Jl3dfaultdevice(dom,group,token,skinCode) {
|
|||
this.anime = null;
|
||||
|
||||
this.modelmanager = new ModelManager();
|
||||
console.log(skinCode);
|
||||
getPublish3dMapDetail(skinCode).then(netdata => {
|
||||
let netDataAssets = JSON.parse(netdata.data.assets);
|
||||
setpsdstationmap(JSON.parse(netdata.data.stands));
|
||||
|
@ -206,7 +203,6 @@ export function Jl3dfaultdevice(dom,group,token,skinCode) {
|
|||
}
|
||||
|
||||
this.selectmodel = function (data) {
|
||||
console.log(data);
|
||||
if (scope.showmodel) {
|
||||
|
||||
if (scope.showmodel.code != data.code) {
|
||||
|
@ -250,7 +246,6 @@ export function Jl3dfaultdevice(dom,group,token,skinCode) {
|
|||
}
|
||||
|
||||
if (data.type == "STAND") {
|
||||
// console.log(data);
|
||||
scope.modelmanager.standmodel.code = data.code;
|
||||
scope.showmodel = scope.modelmanager.standmodel.mesh;
|
||||
scope.scene.add(scope.showmodel);
|
||||
|
@ -267,7 +262,6 @@ export function Jl3dfaultdevice(dom,group,token,skinCode) {
|
|||
|
||||
}
|
||||
if (data.type == "SECTION") {
|
||||
// console.log(data);
|
||||
scope.modelmanager.sectionmodel.code = data.code;
|
||||
scope.showmodel = scope.modelmanager.sectionmodel.mesh;
|
||||
scope.scene.add(scope.showmodel);
|
||||
|
@ -285,7 +279,6 @@ export function Jl3dfaultdevice(dom,group,token,skinCode) {
|
|||
} else {
|
||||
scope.nowcode = data.code;
|
||||
if (data.type == "room") {
|
||||
// console.log(scope.modelmanager.roommodel.mesh);
|
||||
scope.showmodel = scope.modelmanager.roommodel.mesh;
|
||||
scope.scene.add(scope.showmodel);
|
||||
scope.camera.position.set(5, 7, -9);
|
||||
|
@ -409,7 +402,6 @@ export function Jl3dfaultdevice(dom,group,token,skinCode) {
|
|||
}
|
||||
|
||||
settext(scope.animationmodel,scope.animationmodel.position);
|
||||
// console.log(scope.animationmodel);
|
||||
helpbox = new THREE.BoxHelper( scope.animationmodel, 0xff0000 );
|
||||
moveanima.updatehelpbox(helpbox,textplane);
|
||||
// settext(intersects[0].object,intersects[0].point);
|
||||
|
@ -548,13 +540,11 @@ export function Jl3dfaultdevice(dom,group,token,skinCode) {
|
|||
scope.modelmanager.standmodel.action.play();
|
||||
}
|
||||
this.updateselect = function(updata){
|
||||
// console.log(updata);
|
||||
if(helpbox){
|
||||
scope.scene.remove( helpbox );
|
||||
helpbox = null;
|
||||
}
|
||||
helpbox = new THREE.BoxHelper( updata.mesh, 0xff0000 );
|
||||
// console.log(updata.mesh);
|
||||
let point = {
|
||||
x:updata.mesh.matrixWorld.elements[12],
|
||||
y:updata.mesh.matrixWorld.elements[13],
|
||||
|
@ -566,7 +556,6 @@ export function Jl3dfaultdevice(dom,group,token,skinCode) {
|
|||
}
|
||||
|
||||
function getdevicemsg(selectname){
|
||||
// console.log(selectname);
|
||||
for(let i=0,leni=scope.devicetext.devicelist.length;i<leni;i++){
|
||||
|
||||
if(selectname == scope.devicetext.devicelist[i].name){
|
||||
|
@ -730,7 +719,6 @@ export function Jl3dfaultdevice(dom,group,token,skinCode) {
|
|||
textplane.position.x = point.x;
|
||||
textplane.position.y = point.y+6;
|
||||
textplane.position.z = point.z;
|
||||
// console.log(textplane.position);
|
||||
// textplane.tcode = data[i].code;
|
||||
textplane.rotation.y = -Math.PI/2;
|
||||
textplane.lookAt(scope.camera.position);
|
||||
|
@ -764,7 +752,6 @@ export function Jl3dfaultdevice(dom,group,token,skinCode) {
|
|||
ctx.textAlign = 'center';
|
||||
ctx.textBaseline = 'middle';
|
||||
ctx.clearRect(0,0,256,128);
|
||||
//console.log(text.groupNumber);
|
||||
ctx.drawImage(beauty,0,0,256, 128);
|
||||
ctx.fillText("设备部件:"+text, 90,30);
|
||||
// ctx.fillText("车组人员:XXX", 40,20);
|
||||
|
|
|
@ -700,7 +700,6 @@ export function jl3dFaultDeviceVr(dom,group,skinCode) {
|
|||
function onSelectStart( event ) {
|
||||
|
||||
var controller = event.target;
|
||||
// console.log(event);
|
||||
let clickGui = getGuiButton(controller);
|
||||
if(clickGui.length > 0){
|
||||
if(positionStatus == "dm"){
|
||||
|
@ -853,9 +852,7 @@ export function jl3dFaultDeviceVr(dom,group,skinCode) {
|
|||
|
||||
}else{
|
||||
var intersections = getIntersections( controller );
|
||||
// console.log(intersections);
|
||||
if ( intersections) {
|
||||
// console.log(intersections);
|
||||
var intersection = intersections[ 0 ];
|
||||
if(intersection.distance <3.5){
|
||||
if(positionStatus != intersection.object.name){
|
||||
|
@ -886,14 +883,12 @@ export function jl3dFaultDeviceVr(dom,group,skinCode) {
|
|||
let posx = intersection.point.x - trainControl.toptrain.position.x;
|
||||
let posz = intersection.point.z - trainControl.toptrain.position.z;
|
||||
human.position.set( posx, intersection.point.y+0.6, posz);
|
||||
// console.log(human.position);
|
||||
}
|
||||
if(positionStatus == "downfloor"){
|
||||
let posx = trainControl.downtrain.position.x - intersection.point.x;
|
||||
let posz = trainControl.downtrain.position.z - intersection.point.z;
|
||||
|
||||
human.position.set( posx, intersection.point.y+0.6, posz);
|
||||
// console.log(human.position);
|
||||
}
|
||||
let postData = {
|
||||
type:"syn",
|
||||
|
@ -929,9 +924,7 @@ export function jl3dFaultDeviceVr(dom,group,skinCode) {
|
|||
// if ( intersections.length > 0 ) {
|
||||
//
|
||||
// // for(){}
|
||||
// // console.log(intersections);
|
||||
// var intersection = intersections[ 0 ];
|
||||
// // console.log(intersection);
|
||||
// // tempMatrix.getInverse( controller.matrixWorld );
|
||||
// //
|
||||
// // var object = intersection.object;
|
||||
|
@ -957,7 +950,6 @@ export function jl3dFaultDeviceVr(dom,group,skinCode) {
|
|||
}
|
||||
|
||||
function squeezeStart(){
|
||||
console.log("squeeze");
|
||||
scope.modelmanager.otherDevice.action.play();
|
||||
if(positionStatus == "dm"){
|
||||
if(vrPlaneStatus){
|
||||
|
@ -986,7 +978,6 @@ export function jl3dFaultDeviceVr(dom,group,skinCode) {
|
|||
// }
|
||||
|
||||
// settext(scope.animationmodel,scope.animationmodel.position);
|
||||
// console.log(scope.animationmodel);
|
||||
// helpbox = new THREE.BoxHelper( scope.animationmodel, 0xff0000 );
|
||||
// moveanima.updatehelpbox(helpbox,textplane);
|
||||
// settext(intersects[0].object,intersects[0].point);
|
||||
|
@ -1022,7 +1013,6 @@ export function jl3dFaultDeviceVr(dom,group,skinCode) {
|
|||
raycastervr.ray.direction.set( 0, 0, - 1 ).applyMatrix4( tempMatrix );
|
||||
for(let i=0;i<3;i++){
|
||||
let rayObject = raycastervr.intersectObject( floors[i]);
|
||||
// console.log(rayObject);
|
||||
if(rayObject.length>0){
|
||||
return rayObject;
|
||||
}
|
||||
|
@ -1073,7 +1063,6 @@ export function jl3dFaultDeviceVr(dom,group,skinCode) {
|
|||
if ( intersections) {
|
||||
|
||||
var intersection = intersections[ 0 ];
|
||||
// console.log(intersection);
|
||||
if(intersection.distance <3.5){
|
||||
var object = intersection.object;
|
||||
circle.position.set( intersection.point.x, intersection.point.y+0.05, intersection.point.z );
|
||||
|
@ -1131,7 +1120,6 @@ export function jl3dFaultDeviceVr(dom,group,skinCode) {
|
|||
}
|
||||
|
||||
function getdevicemsg(selectname){
|
||||
// console.log(selectname);
|
||||
for(let i=0,leni=scope.devicetext.devicelist.length;i<leni;i++){
|
||||
|
||||
if(selectname == scope.devicetext.devicelist[i].name){
|
||||
|
@ -1205,7 +1193,6 @@ export function jl3dFaultDeviceVr(dom,group,skinCode) {
|
|||
|
||||
|
||||
}
|
||||
// console.log(scope.nowstation);
|
||||
}
|
||||
|
||||
function initstationanimation(object){
|
||||
|
|
|
@ -299,7 +299,6 @@ export function MoveanimateVr(main){
|
|||
}
|
||||
//动画播放器
|
||||
this.animateupdate = function(){
|
||||
// console.log(scope.animatelist);
|
||||
|
||||
if(scope.enable){
|
||||
if(scope.playlist){
|
||||
|
@ -335,7 +334,6 @@ export function MoveanimateVr(main){
|
|||
|
||||
|
||||
}else{
|
||||
// console.log(scope.animatelist[k].connectmodel);
|
||||
if(scope.nowmodelname != scope.playlist[scope.playorder][i].connectmodel.name){
|
||||
scope.nowmodelname = scope.playlist[scope.playorder][i].connectmodel.name;
|
||||
main.animationmsgshowon(scope.playlist[scope.playorder][i].connectmodel);
|
||||
|
|
|
@ -277,8 +277,6 @@ export function VrGui(){
|
|||
//
|
||||
// let nowGroupComponent = scope.homeGroup;
|
||||
this.setStationPlane = function(stations){
|
||||
// console.log(stations);
|
||||
// console.log(textures);
|
||||
let posX,posY;
|
||||
for(let i=0,leni = stations.length;i<leni;i++){
|
||||
|
||||
|
@ -368,7 +366,6 @@ export function VrGui(){
|
|||
}
|
||||
|
||||
this.updataDeviceFaultMsg = function(faultData){
|
||||
console.log(faultData);
|
||||
let textt = new THREE.CanvasTexture(getTextCanvas(faultData,"faultMsg"));
|
||||
scope.deviceGroup.getObjectByName("deviceText").material.map = textt;
|
||||
scope.deviceGroup.getObjectByName("deviceText").material.map.needsUpdate = true;
|
||||
|
@ -474,7 +471,6 @@ export function VrGui(){
|
|||
ctx.textAlign = 'center';
|
||||
ctx.textBaseline = 'middle';
|
||||
ctx.clearRect(0,0,128,64);
|
||||
//console.log(text.groupNumber);
|
||||
ctx.drawImage(beauty,0,0,128, 64);
|
||||
ctx.fillText(text.name, 64,32);
|
||||
//ctx.fillText(text.trainModel.name, width/2,height*3/4);
|
||||
|
@ -493,7 +489,6 @@ export function VrGui(){
|
|||
ctx.textAlign = 'center';
|
||||
ctx.textBaseline = 'middle';
|
||||
ctx.clearRect(0,0,128,64);
|
||||
//console.log(text.groupNumber);
|
||||
ctx.drawImage(beauty,0,0,128, 64);
|
||||
ctx.fillText("故障设备编号:", 64,16);
|
||||
ctx.fillText(text.name, 64,48);
|
||||
|
@ -513,7 +508,6 @@ export function VrGui(){
|
|||
ctx.textAlign = 'center';
|
||||
ctx.textBaseline = 'middle';
|
||||
ctx.clearRect(0,0,256,256);
|
||||
//console.log(text.groupNumber);
|
||||
ctx.drawImage(beauty,0,0,256, 256);
|
||||
ctx.fillText("当前车站信息", 128,32);
|
||||
ctx.fillText("车站名:"+text.name, 128,64);
|
||||
|
@ -540,7 +534,6 @@ export function VrGui(){
|
|||
ctx.textAlign = 'center';
|
||||
ctx.textBaseline = 'middle';
|
||||
ctx.clearRect(0,0,256,256);
|
||||
//console.log(text.groupNumber);
|
||||
ctx.drawImage(beauty,0,0,256, 256);
|
||||
ctx.fillText("当前故障信息", 128,32);
|
||||
ctx.fillText("故障设备:"+text.code, 128,64);
|
||||
|
|
|
@ -55,13 +55,7 @@ export function Maintainerconnect(jlmap3d,routegroup,jsonwebwork,lablecodemap) {
|
|||
|
||||
|
||||
|
||||
// if(event.data.deviceType == "TRAIN"){
|
||||
// // console.log(event.data);
|
||||
//
|
||||
// }
|
||||
// console.log(event.data);
|
||||
if(event.data.type == "Device_Fault_Set_3D"){
|
||||
// console.log(event.data);
|
||||
let newfault = {
|
||||
code:event.data.body.code,
|
||||
name:'',
|
||||
|
@ -240,19 +234,16 @@ export function Maintainerconnect(jlmap3d,routegroup,jsonwebwork,lablecodemap) {
|
|||
// if(event.data.type == 'TrainRun_3D'){
|
||||
//
|
||||
// for(let i=0,leni=event.data.body.length;i<leni;i++){
|
||||
// // console.log(event.data.body[i]);
|
||||
// trainrunnew(event.data.body[i]);
|
||||
// }
|
||||
// return;
|
||||
// }
|
||||
|
||||
// if(event.data.type == 'TRAIN'){
|
||||
// console.log(event.data);
|
||||
// trainrun(event.data);
|
||||
// }
|
||||
// if (event.data.type== 'SIGNAL' && signallist) {
|
||||
// signalupdate(event.data);
|
||||
// // console.log(event.data);
|
||||
// return;
|
||||
// }
|
||||
//
|
||||
|
@ -282,7 +273,7 @@ export function Maintainerconnect(jlmap3d,routegroup,jsonwebwork,lablecodemap) {
|
|||
return;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
this.updatamap = function(newsectionlist,newlinklist,newsignallist,newstationstandlist,newtrainlisttest,newrealsectionlist,newrails, materiallist, nowaction, scene) {
|
||||
trainlisttest = newtrainlisttest;
|
||||
sectionlist = newsectionlist;
|
||||
|
@ -297,7 +288,6 @@ export function Maintainerconnect(jlmap3d,routegroup,jsonwebwork,lablecodemap) {
|
|||
|
||||
this.socketon = function(topic) {
|
||||
try {
|
||||
// console.log("teststomp");
|
||||
// scope.teststomp.subscribe(topic, callback, header);
|
||||
} catch (error) {
|
||||
console.error('websocket订阅失败');
|
||||
|
@ -348,7 +338,6 @@ export function Maintainerconnect(jlmap3d,routegroup,jsonwebwork,lablecodemap) {
|
|||
}
|
||||
}
|
||||
|
||||
// console.log(data);
|
||||
|
||||
if(trainlisttest.list[code].dispose == "0"){
|
||||
if (data.right == '1') { // 向右
|
||||
|
@ -398,7 +387,6 @@ export function Maintainerconnect(jlmap3d,routegroup,jsonwebwork,lablecodemap) {
|
|||
}
|
||||
if(trainlisttest.list[code].children[1].rotalist.length > 0 || trainlisttest.list[code].children[2].rotalist.length > 0 || trainlisttest.list[code].children[3].rotalist.length > 0 || trainlisttest.list[code].children[4].rotalist.length > 0|| trainlisttest.list[code].children[5].rotalist.length > 0){
|
||||
for(let rs = 1;rs<6;rs++){
|
||||
//console.log(rs);
|
||||
if(trainlisttest.list[code].children[rs].rotalist[0]){
|
||||
let offsetz = parseFloat(trainlisttest.list[code].children[rs].rotalist[0].posr.z) - parseFloat(trainlisttest.list[code].children[rs].matrixWorld.elements[14]);
|
||||
|
||||
|
@ -406,11 +394,6 @@ export function Maintainerconnect(jlmap3d,routegroup,jsonwebwork,lablecodemap) {
|
|||
|
||||
for(let xh=0;xh<trainlisttest.list[code].children[rs].rotalist.length;xh++){
|
||||
if((trainlisttest.list[code].children[rs].matrixWorld.elements[12])>=trainlisttest.list[code].children[rs].rotalist[0].posr.x){
|
||||
// if(trainlisttest.list[code].groupNumber == "005"){
|
||||
// console.log("rs:"+rs);
|
||||
// console.log(trainlisttest.list[code].children[rs].matrixWorld.elements[12]);
|
||||
// console.log(trainlisttest.list[code].children[rs].rotalist[0].posr.x);
|
||||
// }
|
||||
if(rs != 5){
|
||||
let asd = trainlisttest.list[code].children[rs].rotalist[0];
|
||||
trainlisttest.list[code].children[rs+1].rotalist.push(asd);
|
||||
|
@ -424,7 +407,6 @@ export function Maintainerconnect(jlmap3d,routegroup,jsonwebwork,lablecodemap) {
|
|||
xh = trainlisttest.list[code].children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainlisttest.list[code].children[rs].rotalist.length);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -481,7 +463,6 @@ export function Maintainerconnect(jlmap3d,routegroup,jsonwebwork,lablecodemap) {
|
|||
if(trainlisttest.list[code].children[1].rotalist.length > 0 || trainlisttest.list[code].children[2].rotalist.length > 0 || trainlisttest.list[code].children[3].rotalist.length > 0 || trainlisttest.list[code].children[4].rotalist.length > 0|| trainlisttest.list[code].children[5].rotalist.length > 0){
|
||||
|
||||
for(let rs = 1;rs<6;rs++){
|
||||
//console.log(rs);
|
||||
if(trainlisttest.list[code].children[rs].rotalist[0]){
|
||||
|
||||
let offsetz = parseFloat(trainlisttest.list[code].children[rs].rotalist[0].posr.z) + parseFloat(trainlisttest.list[code].children[rs].position.z);
|
||||
|
@ -504,13 +485,11 @@ export function Maintainerconnect(jlmap3d,routegroup,jsonwebwork,lablecodemap) {
|
|||
xh = trainlisttest.list[code].children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainlisttest.list[code].children[rs].rotalist.length);
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
// console.log(trainlisttest.list[code].rotalist);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -523,7 +502,6 @@ export function Maintainerconnect(jlmap3d,routegroup,jsonwebwork,lablecodemap) {
|
|||
}
|
||||
function trainrun(data){
|
||||
let code = data.code;
|
||||
// console.log(data);
|
||||
if(trainlisttest.list[code].dispose == "0"){
|
||||
if(trainlisttest.list[code].curve == null){
|
||||
if (data.right == '1') { // 向右
|
||||
|
|
|
@ -76,7 +76,6 @@ export function PassflowConnect(deviceaction, toptrain, downtrain, routegroup, p
|
|||
|
||||
}
|
||||
if (downtrain.nowcode == data.body.trainCode) {
|
||||
// console.log(data.body);
|
||||
if (data.body.command == 'G') {
|
||||
closetraindoor(downtrain, data.body.code, 'down');
|
||||
|
||||
|
|
|
@ -221,7 +221,6 @@ export function Jl3dpassflow(dom,skinCode,routegroup,viewMap) {
|
|||
passerAi.initPasser(humanlist,passerHuman);
|
||||
let updateaianimate = setInterval(
|
||||
function(){
|
||||
// console.log("?");
|
||||
if(aiswitch == 0){
|
||||
passerHuman.moveAnimateUpdate(humanlist,olddataai,passerHuman);
|
||||
passerAi.aiUpdate(humanlist,passerHuman,passerCheckDoor,deviceaction);
|
||||
|
@ -244,7 +243,6 @@ export function Jl3dpassflow(dom,skinCode,routegroup,viewMap) {
|
|||
|
||||
passerWebWork.onmessage = function (event) {
|
||||
if(aiswitch == 0){
|
||||
// console.log(humanlist.children.length);
|
||||
if(humanlist.children.length < 80){
|
||||
let direct = Math.floor(Math.random()*(3-1+1))+1;
|
||||
//1--top
|
||||
|
|
|
@ -101,7 +101,6 @@ export function ModelManager(){
|
|||
Promise.all(initlist).then((result) => {
|
||||
resolve("success"); //['成功了', 'success']
|
||||
}).catch((error) => {
|
||||
//console.log(error);
|
||||
});
|
||||
|
||||
});
|
||||
|
|
|
@ -61,7 +61,6 @@ export function PasserHuman() {
|
|||
newhuman.speed = 0;
|
||||
newhuman.mixer = mixer;
|
||||
humanlist.add(newhuman);
|
||||
// console.log(humanlist.children.length);
|
||||
}
|
||||
//定义新模型走路动画
|
||||
this.initMoveAnimate = function(model,name,points,index){
|
||||
|
@ -73,7 +72,6 @@ export function PasserHuman() {
|
|||
// progress动画进度
|
||||
// enable当前动画开关
|
||||
// speed动画速度
|
||||
// console.log(curve);
|
||||
|
||||
model.action.play();
|
||||
model.progress = 0;
|
||||
|
@ -129,7 +127,6 @@ export function PasserHuman() {
|
|||
humanlist.children[i].stage = 2;
|
||||
|
||||
}else if(humanlist.children[i].stage == 0){
|
||||
// // console.log(humans[i].doors);
|
||||
// zhajiin[humanlist.children[i].doors].waiting = 0;
|
||||
humanlist.children[i].stage = 1;
|
||||
}
|
||||
|
@ -138,9 +135,6 @@ export function PasserHuman() {
|
|||
|
||||
}else{
|
||||
//根据动画进度获取动画轨迹上点
|
||||
// console.log(i);
|
||||
// console.log(humanlist.children[i].runrail);
|
||||
// console.log(humanlist.children[i].progress);
|
||||
let point = humanlist.children[i].runrail.getPointAt(humanlist.children[i].progress);
|
||||
|
||||
//更新模型坐标
|
||||
|
|
|
@ -87,7 +87,6 @@ export function PasserStation() {
|
|||
|
||||
} );
|
||||
scope.stationMesh = object;
|
||||
// console.log(deviceaction);
|
||||
scene.add(object);
|
||||
|
||||
}
|
||||
|
|
|
@ -188,10 +188,8 @@ export function ZoneManager() {
|
|||
}
|
||||
//获取区域范围内点
|
||||
this.getinitposition = function(name){
|
||||
// console.log(scope.list[name]);
|
||||
let randompoint = new THREE.Vector3(0,scope.list[name].randompoint.y,0);
|
||||
|
||||
// console.log(randompoint);
|
||||
if(name == "enter1"){
|
||||
randompoint.x = scope.list[name].randompoint.x + Math.random()*8;
|
||||
randompoint.z = scope.list[name].randompoint.z + Math.random()*8;
|
||||
|
|
|
@ -243,11 +243,8 @@ export function Moveanimate(main){
|
|||
// points.push(new THREE.Vector3(switchmodel.children[i].position.x,switchmodel.children[i].position.y,switchmodel.children[i].position.z));
|
||||
// scope.initanimate(switchmodel.children[i],switchmodel.name+"select1",points,true);
|
||||
let modelorderlist = [];
|
||||
console.log(switchmodel);
|
||||
for(let i=0;i<switchmodel.children.length;i++){
|
||||
console.log(switchmodel.children[i].name);
|
||||
console.log(switchmodel.children[i]);
|
||||
}
|
||||
// for(let i=0;i<switchmodel.children.length;i++){
|
||||
// }
|
||||
modelorderlist[switchmodel.animacode] = [
|
||||
{name:"SJ",pos:[-3.5,0,-1]},
|
||||
{name:"ZZJJG",pos:[0,9,0]},
|
||||
|
@ -275,16 +272,12 @@ export function Moveanimate(main){
|
|||
|
||||
scope.animatelist[switchmodel.animacode+"on"] = [];
|
||||
scope.animatelist[switchmodel.animacode+"off"] = [];
|
||||
console.log("==========");
|
||||
for(let i=0,leni=modelorderlist[switchmodel.animacode].length;i<leni;i++){
|
||||
|
||||
let orderdata = modelorderlist[switchmodel.animacode];
|
||||
|
||||
console.log(switchmodel.animacode);
|
||||
console.log(orderdata[i].name);
|
||||
let modelon = switchmodel.getObjectByName(orderdata[i].name);
|
||||
// modelon.helpbox = undefined;
|
||||
console.log(modelon);
|
||||
let pointson = [];
|
||||
pointson.push(new THREE.Vector3(modelon.position.x,modelon.position.y,modelon.position.z));
|
||||
pointson.push(new THREE.Vector3(modelon.position.x+orderdata[i].pos[0],modelon.position.y+orderdata[i].pos[1],modelon.position.z+orderdata[i].pos[2]));
|
||||
|
@ -401,7 +394,6 @@ export function Moveanimate(main){
|
|||
}
|
||||
|
||||
}else{
|
||||
// console.log(scope.animatelist[k].connectmodel);
|
||||
if(scope.nowmodelname != scope.playlist[scope.playorder][i].connectmodel.name){
|
||||
scope.nowmodelname = scope.playlist[scope.playorder][i].connectmodel.name;
|
||||
main.animationmsgshowon(scope.playlist[scope.playorder][i].connectmodel);
|
||||
|
|
|
@ -232,9 +232,6 @@ export function Textconfig(){
|
|||
part.msg = "用于机内外电缆连接,方便更换转辙机。";
|
||||
selectmodel.children[i].text = "二十位插接件";
|
||||
}
|
||||
// if(part.text == null){
|
||||
// console.log(selectmodel.children[i].name);
|
||||
// }
|
||||
if(part.text){
|
||||
scope.devicelist.push(part);
|
||||
}
|
||||
|
|
|
@ -856,10 +856,6 @@ export function Jl3ddeviceNew(dom,group,token,skinCode) {
|
|||
}
|
||||
}
|
||||
|
||||
if (data._type == "Signal") {
|
||||
console.log(data);
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -423,7 +423,6 @@ export function JLmapDriving(dom,data,mapId,storemod,translation,routegroup,proj
|
|||
realsectionlist = loadrealsectionlist;
|
||||
rails = loadrails;
|
||||
|
||||
console.log(trainlisttest.group);
|
||||
trainlisttest.group.children[0].add(cameracctv);
|
||||
}
|
||||
|
||||
|
|
|
@ -183,7 +183,6 @@ export function AssetLoader(){
|
|||
// return fbxpromise(autosuidao);
|
||||
// })
|
||||
.then(function(data){
|
||||
// console.log("defaultswitch1");
|
||||
return fbxpromise(defaultswitch1);
|
||||
})
|
||||
.then(function(data){
|
||||
|
|
|
@ -223,7 +223,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,sta
|
|||
// if(updateTrainModel.children[1].rotalist.length > 0 || updateTrainModel.children[2].rotalist.length > 0 || updateTrainModel.children[3].rotalist.length > 0 || updateTrainModel.children[4].rotalist.length > 0|| updateTrainModel.children["black"].rotalist.length > 0){
|
||||
|
||||
for(let rs = 1;rs<updateTrainModel.children.length;rs++){
|
||||
//console.log(rs);
|
||||
if(updateTrainModel.children[rs].rotalist[0]){
|
||||
|
||||
let offsetz = parseFloat(updateTrainModel.children[rs].rotalist[0].posr.z) + parseFloat(updateTrainModel.children[rs].position.z);
|
||||
|
@ -246,13 +245,11 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,sta
|
|||
xh = updateTrainModel.children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainmodel.children[rs].rotalist.length);
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
// console.log(trainmodel.rotalist);
|
||||
// }
|
||||
|
||||
}else{
|
||||
|
@ -298,7 +295,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,sta
|
|||
|
||||
// if(updateTrainModel.children[1].rotalist.length > 0 || updateTrainModel.children[2].rotalist.length > 0 || updateTrainModel.children[3].rotalist.length > 0 || updateTrainModel.children[4].rotalist.length > 0|| updateTrainModel.children["black"].rotalist.length > 0){
|
||||
for(let rs = 1;rs<updateTrainModel.children.length;rs++){
|
||||
//console.log(rs);
|
||||
if(updateTrainModel.children[rs].rotalist[0]){
|
||||
let offsetz = parseFloat(updateTrainModel.children[rs].rotalist[0].posr.z) - parseFloat(updateTrainModel.children[rs].matrixWorld.elements[14]);
|
||||
|
||||
|
|
|
@ -4,11 +4,9 @@ export function UpdateTrain(camera,traindata,control){
|
|||
if(traindata != undefined && traindata.group.children[0]){//traindata.group.children[0].dispose == false
|
||||
|
||||
if(traindata.group.children[0].progress != null){
|
||||
// console.log(traindata.group);
|
||||
let trainmodel = traindata.group.children[0];
|
||||
if(trainmodel.speeds > 0 && trainmodel.speeds){
|
||||
let speed = null;
|
||||
// console.log(traindata.group.children[0].progress);
|
||||
if(traindata.group.children[0].progress >=0&&traindata.group.children[0].progress<=1){
|
||||
|
||||
let movecurve = trainmodel.curve;
|
||||
|
@ -44,7 +42,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
|
||||
if(trainmodel.children[1].rotalist.length > 0 || trainmodel.children[2].rotalist.length > 0 || trainmodel.children[3].rotalist.length > 0 || trainmodel.children[4].rotalist.length > 0|| trainmodel.children[5].rotalist.length > 0){
|
||||
for(let rs = 1;rs<6;rs++){
|
||||
//console.log(rs);
|
||||
if(trainmodel.children[rs].rotalist[0]){
|
||||
let offsetz = parseFloat(trainmodel.children[rs].matrixWorld.elements[14]) - parseFloat(trainmodel.children[rs].rotalist[0].posr.z);
|
||||
|
||||
|
@ -66,7 +63,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
xh = trainmodel.children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainmodel.children[rs].rotalist.length);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -103,7 +99,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
if(trainmodel.children[1].rotalist.length > 0 || trainmodel.children[2].rotalist.length > 0 || trainmodel.children[3].rotalist.length > 0 || trainmodel.children[4].rotalist.length > 0|| trainmodel.children[5].rotalist.length > 0){
|
||||
|
||||
for(let rs = 1;rs<6;rs++){
|
||||
//console.log(rs);
|
||||
if(trainmodel.children[rs].rotalist[0]){
|
||||
|
||||
let offsetz = parseFloat(trainmodel.children[rs].rotalist[0].posr.z) - parseFloat(trainmodel.children[rs].matrixWorld.elements[14]);
|
||||
|
@ -126,13 +121,10 @@ export function UpdateTrain(camera,traindata,control){
|
|||
xh = trainmodel.children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainmodel.children[rs].rotalist.length);
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
// console.log(trainmodel.rotalist);
|
||||
}
|
||||
trainmodel.progress += trainmodel.speeds;
|
||||
}
|
||||
|
@ -152,9 +144,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
trainmodel.nextcode = null;
|
||||
}
|
||||
|
||||
// console.log(trainmodel.name);
|
||||
// console.log(trainmodel.progress);
|
||||
// console.log(trainmodel.nextcurve);
|
||||
// if(trainmodel.status == "02"){
|
||||
// trainmodel.progress = 0;
|
||||
// }else if(trainmodel.status == "03"){
|
||||
|
@ -197,7 +186,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
|
||||
if(trainmodel.children[1].rotalist.length > 0 || trainmodel.children[2].rotalist.length > 0 || trainmodel.children[3].rotalist.length > 0 || trainmodel.children[4].rotalist.length > 0|| trainmodel.children[5].rotalist.length > 0){
|
||||
for(let rs = 1;rs<6;rs++){
|
||||
//console.log(rs);
|
||||
if(trainmodel.children[rs].rotalist[0]){
|
||||
let offsetz = parseFloat(trainmodel.children[rs].matrixWorld.elements[14]) - parseFloat(trainmodel.children[rs].rotalist[0].posr.z);
|
||||
|
||||
|
@ -219,7 +207,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
xh = trainmodel.children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainmodel.children[rs].rotalist.length);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -256,7 +243,6 @@ export function UpdateTrain(camera,traindata,control){
|
|||
if(trainmodel.children[1].rotalist.length > 0 || trainmodel.children[2].rotalist.length > 0 || trainmodel.children[3].rotalist.length > 0 || trainmodel.children[4].rotalist.length > 0|| trainmodel.children[5].rotalist.length > 0){
|
||||
|
||||
for(let rs = 1;rs<6;rs++){
|
||||
//console.log(rs);
|
||||
if(trainmodel.children[rs].rotalist[0]){
|
||||
|
||||
let offsetz = parseFloat(trainmodel.children[rs].rotalist[0].posr.z) - parseFloat(trainmodel.children[rs].matrixWorld.elements[14]);
|
||||
|
@ -279,16 +265,12 @@ export function UpdateTrain(camera,traindata,control){
|
|||
xh = trainmodel.children[rs].rotalist.length;
|
||||
}
|
||||
}
|
||||
//console.log(trainmodel.children[rs].rotalist.length);
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
// console.log(trainmodel.rotalist);
|
||||
}
|
||||
|
||||
// console.log(trainmodel.nextcurve);
|
||||
if(trainmodel.progress > -(trainmodel.speeds)){
|
||||
trainmodel.progress += trainmodel.speeds;
|
||||
}
|
||||
|
|
|
@ -141,7 +141,6 @@ export function silumationConnect(deviceaction,toptrain,downtrain,routegroup,pas
|
|||
start = true;
|
||||
toptrain.nowcode = null;
|
||||
downtrain.nowcode = null;
|
||||
console.log("仿真重开=====================");
|
||||
}
|
||||
|
||||
|
||||
|
@ -156,7 +155,6 @@ export function silumationConnect(deviceaction,toptrain,downtrain,routegroup,pas
|
|||
let actions;
|
||||
|
||||
function opentraindoor(train,doorcode,direct){
|
||||
// console.log(train);
|
||||
if(direct == "top"){
|
||||
// if(doorcode == "1"){
|
||||
// actions = train.action.down;
|
||||
|
|
|
@ -57,7 +57,6 @@ export function stationConnect(deviceaction,toptrain,downtrain,routegroup,passer
|
|||
|
||||
if(passerStation.stationlist[j].topstand == newStandData[i].standCode){
|
||||
|
||||
// console.log(passerStation.stationlist[j]);
|
||||
passerStation.stationlist[j].topspeed = newStandData[i].to;
|
||||
passerStation.stationlist[j].toppassers = newStandData[i].num;
|
||||
count++;
|
||||
|
@ -70,7 +69,6 @@ export function stationConnect(deviceaction,toptrain,downtrain,routegroup,passer
|
|||
}
|
||||
|
||||
if(count == 2){
|
||||
// console.log(passerStation.stationlist[j]);
|
||||
i = newStandData.length;
|
||||
}
|
||||
}
|
||||
|
@ -116,7 +114,6 @@ export function stationConnect(deviceaction,toptrain,downtrain,routegroup,passer
|
|||
let actions;
|
||||
|
||||
function opentraindoor(train,doorcode,direct){
|
||||
// console.log(train);
|
||||
if(direct == "top"){
|
||||
// if(doorcode == "1"){
|
||||
// actions = train.action.down;
|
||||
|
|
|
@ -218,7 +218,6 @@ export function Jl3dStationManager(dom,skinCode,routegroup,initCode) {
|
|||
});
|
||||
|
||||
this.initTrafficStart = function(){
|
||||
console.log("initTrafficStart");
|
||||
passerStation.initCodeStation(initCode);
|
||||
scope.humanWaitTop = passerStation.nowStation.toppassers;
|
||||
scope.humanWaitDown = passerStation.nowStation.downpassers;
|
||||
|
@ -233,7 +232,6 @@ export function Jl3dStationManager(dom,skinCode,routegroup,initCode) {
|
|||
|
||||
this.changestation = function(stationname){
|
||||
passerStation.changestation(stationname);
|
||||
// console.log(passerStation.nowStation);
|
||||
scope.humanWaitTop = passerStation.nowStation.toppassers;
|
||||
scope.humanWaitDown = passerStation.nowStation.downpassers;
|
||||
passerHuman.speed = passerStation.nowStation.topspeed + passerStation.nowStation.downspeed;
|
||||
|
@ -244,7 +242,6 @@ export function Jl3dStationManager(dom,skinCode,routegroup,initCode) {
|
|||
}
|
||||
|
||||
this.updateNowStationData = function(){
|
||||
// console.log(passerStation.nowStation);
|
||||
for(let i=0;i<passerStation.nowStation.topspeed;i++){
|
||||
let newIn = {
|
||||
overGoal:"top",
|
||||
|
@ -350,7 +347,6 @@ export function Jl3dStationManager(dom,skinCode,routegroup,initCode) {
|
|||
|
||||
updateaianimate = setInterval(
|
||||
function(){
|
||||
// console.log("?");
|
||||
if(aiswitch == 0){
|
||||
updatePasserData(humanlist.children.length,topWaitPassers.children.length,downWaitPassers.children.length,outStationPassers.children.length,passerHuman.speed);
|
||||
|
||||
|
@ -393,12 +389,8 @@ export function Jl3dStationManager(dom,skinCode,routegroup,initCode) {
|
|||
|
||||
passerWebWork.onmessage = function (event) {
|
||||
if(aiswitch == 0){
|
||||
// console.log(humanlist.children.length);
|
||||
// console.log(sceneRegion.startRegion.group.children);
|
||||
this.allStationData = [];
|
||||
// console.log(Math.random());
|
||||
|
||||
// console.log(waitForCreatIn);
|
||||
if(waitForCreatIn.length>0){
|
||||
let randomNum = Math.random();
|
||||
let startNum = 0;
|
||||
|
@ -437,7 +429,6 @@ export function Jl3dStationManager(dom,skinCode,routegroup,initCode) {
|
|||
// raycaster.setFromCamera( mouse, camerass );
|
||||
//
|
||||
// let intersects = raycaster.intersectObject(scope.modelmanager.station.mesh,true);
|
||||
// console.log(intersects[0].point);
|
||||
// }
|
||||
// }
|
||||
|
||||
|
@ -555,7 +546,6 @@ export function Jl3dStationManager(dom,skinCode,routegroup,initCode) {
|
|||
//循环渲染函数
|
||||
function animate() {
|
||||
render();
|
||||
// console.log(passerRender);
|
||||
// if(passerRender.state == "freeview"){
|
||||
controls.update();
|
||||
// }
|
||||
|
|
|
@ -124,7 +124,6 @@ export function ModelManager(){
|
|||
return new Promise(function(resolve, reject){
|
||||
|
||||
Promise.all(initlist).then((result) => {
|
||||
// console.log("success");
|
||||
store.dispatch('app/animationsClose');
|
||||
resolve("success"); //['成功了', 'success']
|
||||
}).catch((error) => {
|
||||
|
|
|
@ -124,11 +124,9 @@ export function PasserHuman() {
|
|||
if(direct == "top"){
|
||||
waitForCreatOutTop = getnum(outNum,standRegion.belongList["top"].length-1);
|
||||
|
||||
// console.log(waitForCreatOutTop);
|
||||
for(let i=0;i<waitForCreatOutTop.length;i++){
|
||||
for(let j=0;j<waitForCreatOutTop[i];j++){
|
||||
setTimeout(function(){
|
||||
// console.log(sceneRegion.list["standtop"].doorpoints[i]);
|
||||
|
||||
createLeaveHumanModel(outStationPassers,standRegion.belongList["top"][i].position,startRegion);
|
||||
}, Math.random()*1000*j);
|
||||
|
@ -139,7 +137,6 @@ export function PasserHuman() {
|
|||
for(let i=0;i<waitForCreatOutDown.length;i++){
|
||||
for(let j=0;j<waitForCreatOutDown[i];j++){
|
||||
setTimeout(function(){
|
||||
// console.log(sceneRegion.list["standdown"].doorpoints[i]);
|
||||
createLeaveHumanModel(outStationPassers,standRegion.belongList["down"][i].position,startRegion);
|
||||
}, Math.random()*1000*j);
|
||||
}
|
||||
|
@ -240,7 +237,6 @@ export function PasserHuman() {
|
|||
// progress动画进度
|
||||
// enable当前动画开关
|
||||
// speed动画速度
|
||||
// console.log(curve);
|
||||
|
||||
// model.action.play();
|
||||
model.progress = 0;
|
||||
|
@ -303,9 +299,6 @@ export function PasserHuman() {
|
|||
}
|
||||
}else{
|
||||
//根据动画进度获取动画轨迹上点
|
||||
// console.log(i);
|
||||
// console.log(humanlist.children[i].runrail);
|
||||
// console.log(humanlist.children[i].progress);
|
||||
let point = topWaitPassers.children[i].runrail.getPointAt(topWaitPassers.children[i].progress);
|
||||
|
||||
//更新模型坐标
|
||||
|
@ -338,9 +331,6 @@ export function PasserHuman() {
|
|||
}
|
||||
}else{
|
||||
//根据动画进度获取动画轨迹上点
|
||||
// console.log(i);
|
||||
// console.log(humanlist.children[i].runrail);
|
||||
// console.log(humanlist.children[i].progress);
|
||||
let point = downWaitPassers.children[i].runrail.getPointAt(downWaitPassers.children[i].progress);
|
||||
|
||||
//更新模型坐标
|
||||
|
@ -391,16 +381,11 @@ export function PasserHuman() {
|
|||
humanlist.children[i].nowGoal = "checkRegion";
|
||||
|
||||
}else if(humanlist.children[i].nowGoal == "ticketRegion"){
|
||||
// // console.log(humans[i].doors);
|
||||
// zhajiin[humanlist.children[i].doors].waiting = 0;
|
||||
humanlist.children[i].nowGoal = "securityRegion";
|
||||
}
|
||||
|
||||
}else{
|
||||
//根据动画进度获取动画轨迹上点
|
||||
// console.log(i);
|
||||
// console.log(humanlist.children[i].runrail);
|
||||
// console.log(humanlist.children[i].progress);
|
||||
let point = humanlist.children[i].runrail.getPointAt(humanlist.children[i].progress);
|
||||
|
||||
//更新模型坐标
|
||||
|
|
|
@ -42,7 +42,6 @@ export function PasserStation() {
|
|||
|
||||
let newclip = object.animations[ 0 ];
|
||||
let standfloor = object.getObjectByName("1CENG");
|
||||
console.log(object);
|
||||
for(let j=0;j<standfloor.children.length;j++){
|
||||
|
||||
if(standfloor.children[j].name == "top"){
|
||||
|
@ -102,7 +101,6 @@ export function PasserStation() {
|
|||
originDownPosition.copy(scope.down.position);
|
||||
scope.topfloor = object.getObjectByName("1floor");
|
||||
scope.downfloor = object.getObjectByName("2floor");
|
||||
// console.log(deviceaction);
|
||||
scene.add(object);
|
||||
|
||||
}
|
||||
|
@ -185,9 +183,7 @@ export function PasserStation() {
|
|||
};
|
||||
|
||||
this.initCodeStation = function(initCode){
|
||||
console.log(scope.stationlist);
|
||||
for(let i=0,leni=scope.stationlist.length;i<leni;i++){
|
||||
// console.log(scope.stationlist[i]);
|
||||
if(scope.stationlist[i].downstand == initCode || scope.stationlist[i].topstand == initCode){
|
||||
scope.nowStation = scope.stationlist[i];
|
||||
|
||||
|
@ -203,7 +199,7 @@ export function PasserStation() {
|
|||
|
||||
this.apartPosition = function(drawGroup,zhajiin,zhajiout){
|
||||
// scope.down.position.y = scope.top.position.y;
|
||||
|
||||
|
||||
scope.top.position.z += 75;
|
||||
scope.down.position.z -= 75;
|
||||
zhajiin.position.z -= 75;
|
||||
|
|
|
@ -55,7 +55,6 @@ export function PasserTrain() {
|
|||
points2.push(new THREE.Vector3(-71,0.06,28.68));
|
||||
points2.push(new THREE.Vector3(60.73,0.06,28.68));
|
||||
scope.downtrain.curve = new THREE.CatmullRomCurve3(points2);
|
||||
// console.log(scope.toptrain);
|
||||
|
||||
inittrainanimation(scope.toptrain,tclip,fclip,mixers);
|
||||
inittrainanimation(scope.downtrain,tclip,fclip,mixers);
|
||||
|
@ -74,7 +73,6 @@ export function PasserTrain() {
|
|||
|
||||
for(let j=0;j<train.children.length;j++){
|
||||
// if(train.children[j].name == "c1" || train.children[j].name == "c6"){
|
||||
// console.log(train.children[j].children);
|
||||
for(let n=0,lenn = train.children[j].children.length;n<lenn;n++){
|
||||
if(train.children[j].children[n].name == "top"){
|
||||
train.children[j].children[n].animations = [];
|
||||
|
|
|
@ -172,7 +172,7 @@ export function checkRegion(data) {
|
|||
|
||||
for(let i=0;i<newzhaji.children.length;i++){
|
||||
if(newzhaji.children[i].children.length>0){
|
||||
|
||||
|
||||
newzhaji.children[i].animations = [];
|
||||
newzhaji.children[i].animations.push(newclip.clone());
|
||||
|
||||
|
@ -203,7 +203,6 @@ export function checkRegion(data) {
|
|||
//闸机动画控制
|
||||
this.checkDoorControl = function(type,door,deviceaction){
|
||||
let checkDoorId = door;
|
||||
console.log();
|
||||
if(type == "in"){
|
||||
// let checkDoorId = scope.zhajiin[devicenum].id;
|
||||
deviceaction[checkDoorId].action.reset();
|
||||
|
|
|
@ -99,7 +99,6 @@ export function regionManager() {
|
|||
|
||||
//存储区域数据
|
||||
this.saveRegionData = function(){
|
||||
// console.log();
|
||||
let newSaveData = {
|
||||
startRegion:[],
|
||||
securityRegion:[],
|
||||
|
|
|
@ -326,11 +326,6 @@ export function PasserAi(finder,region) {
|
|||
|
||||
if(humanlist.children[i].nowGoal == "inCheck"){
|
||||
let points = [];
|
||||
// console.log();
|
||||
// console.log(region.checkRegion.group.children[humanlist.children[i].checkDoor].position);
|
||||
// console.log(region.checkRegion.group.children[humanlist.children[i].checkDoor].getObjectByName("regionHead").getWorldPosition(new THREE.Vector3()));
|
||||
// console.log(region.checkRegion.group.children[humanlist.children[i].checkDoor].getObjectByName("regionDirect").getWorldPosition(new THREE.Vector3()));
|
||||
// console.log("================");
|
||||
points.push(region.checkRegion.group.children[humanlist.children[i].checkDoor].getObjectByName("regionHead").getWorldPosition(new THREE.Vector3()));
|
||||
points.push(region.checkRegion.group.children[humanlist.children[i].checkDoor].getObjectByName("regionDirect").getWorldPosition(new THREE.Vector3()));
|
||||
|
||||
|
|
|
@ -134,8 +134,6 @@ export function Lesson3dPlayer(dom,lessonData,lessonIndex) {
|
|||
|
||||
|
||||
if(nowIndex == (lessonData.lessonProgress.length-1)){
|
||||
// console.log(nowIndex);
|
||||
// console.log(lessonData.lessonProgress.length);
|
||||
lessonEnd();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -16,16 +16,13 @@ export function AnimateManager() {
|
|||
this.initAnimation = function(assetModelManager){
|
||||
for(let k in assetModelManager.staticAsset){
|
||||
if(assetModelManager.staticAsset[k].mesh.animations.length > 0){
|
||||
// console.log(assetModelManager.staticAsset[k]);
|
||||
if(assetModelManager.staticAsset[k].modelId == "PBMDH"){
|
||||
|
||||
|
||||
// console.log(assetModelManager.staticAsset[k].mesh);
|
||||
let animations = assetModelManager.staticAsset[k].mesh.animations[0];
|
||||
for(let i=0;i <assetModelManager.staticAsset[k].mesh.children.length;i++){
|
||||
if(assetModelManager.staticAsset[k].mesh.children[i].type == "Group"){
|
||||
assetModelManager.staticAsset[k].mesh.children[i].animations = [];
|
||||
//console.log(assetModelManager.staticAsset[k].mesh);
|
||||
|
||||
assetModelManager.staticAsset[k].mesh.children[i].animations.push(animations.clone());
|
||||
let mixer = new THREE.AnimationMixer( assetModelManager.staticAsset[k].mesh.children[i] );
|
||||
|
|
|
@ -70,7 +70,6 @@ export function LessonData() {
|
|||
}
|
||||
|
||||
this.loadLessonProgress = function(loadData){
|
||||
// console.log(loadData);
|
||||
for(let i=0;i<loadData.length;i++){
|
||||
let newLessonProgress = {
|
||||
id:loadData[i].id,
|
||||
|
|
|
@ -239,7 +239,6 @@ export function AssetModelManager(editor,scene) {
|
|||
|
||||
resolve("loaderassets"); //['成功了', 'success']
|
||||
}).catch((error) => {
|
||||
//console.log(error);
|
||||
});
|
||||
|
||||
});
|
||||
|
|
|
@ -593,8 +593,6 @@ THREE.OrbitControlsedit = function ( object, domElement ) {
|
|||
|
||||
function handleTouchMoveRotate( event ) {
|
||||
|
||||
//console.log( 'handleTouchMoveRotate' );
|
||||
|
||||
rotateEnd.set( event.touches[ 0 ].pageX, event.touches[ 0 ].pageY );
|
||||
|
||||
rotateDelta.subVectors( rotateEnd, rotateStart ).multiplyScalar( scope.rotateSpeed );
|
||||
|
@ -613,8 +611,6 @@ THREE.OrbitControlsedit = function ( object, domElement ) {
|
|||
|
||||
function handleTouchMoveDollyPan( event ) {
|
||||
|
||||
//console.log( 'handleTouchMoveDollyPan' );
|
||||
|
||||
if ( scope.enableZoom ) {
|
||||
|
||||
var dx = event.touches[ 0 ].pageX - event.touches[ 1 ].pageX;
|
||||
|
@ -653,8 +649,6 @@ THREE.OrbitControlsedit = function ( object, domElement ) {
|
|||
|
||||
function handleTouchEnd( event ) {
|
||||
|
||||
//console.log( 'handleTouchEnd' );
|
||||
|
||||
}
|
||||
|
||||
//
|
||||
|
|
|
@ -372,30 +372,21 @@ export function AssetLoader() {
|
|||
return fbxpromise(wstation);
|
||||
})
|
||||
// .then(function(data){
|
||||
// ////console.log(data);
|
||||
// return fbxpromise(autorail);
|
||||
// })
|
||||
// .then(function(data){
|
||||
// ////console.log(data);
|
||||
// return fbxpromise(autosuidao);
|
||||
// })
|
||||
.then(function(data) {
|
||||
////console.log(data);
|
||||
// console.log("defaultswitch1");
|
||||
return fbxpromise(defaultswitch1);
|
||||
})
|
||||
.then(function(data) {
|
||||
// console.log("defaultswitch2");
|
||||
////console.log(data);
|
||||
return fbxpromise(defaultswitch2);
|
||||
})
|
||||
.then(function(data) {
|
||||
////console.log(data);
|
||||
// console.log("autoswitchs");
|
||||
return fbxpromise(autoswitchs);
|
||||
})
|
||||
.then(function(data) {
|
||||
////console.log(scope.modellist);
|
||||
resolve("loaderassets");
|
||||
});
|
||||
});
|
||||
|
@ -417,7 +408,6 @@ export function AssetLoader() {
|
|||
let newmesh = object;
|
||||
|
||||
//let mixer = new THREE.AnimationMixer( newmesh );
|
||||
////console.log(jlmap3ddata.sectionlist);
|
||||
for (let i = 0; i < newmesh.children.length; i++) {
|
||||
|
||||
let name = newmesh.children[i].name.split("_");
|
||||
|
@ -503,7 +493,6 @@ export function AssetLoader() {
|
|||
|
||||
scene.add(newmesh);
|
||||
loadingInstance.close();
|
||||
//console.log("add");
|
||||
});
|
||||
|
||||
}
|
||||
|
|
|
@ -3269,8 +3269,6 @@ THREE.FBXLoader = ( function () {
|
|||
|
||||
var version = reader.getUint32();
|
||||
|
||||
console.log( 'THREE.FBXLoader: FBX binary version: ' + version );
|
||||
|
||||
var allNodes = new FBXTree();
|
||||
|
||||
while ( ! this.endOfContent( reader ) ) {
|
||||
|
|
|
@ -485,7 +485,6 @@ export function Moveanimate(main){
|
|||
}
|
||||
|
||||
}else{
|
||||
// console.log(scope.animatelist[k].connectmodel);
|
||||
if(scope.nowmodelname != scope.playlist[scope.playorder][i].connectmodel.name){
|
||||
scope.nowmodelname = scope.playlist[scope.playorder][i].connectmodel.name;
|
||||
main.animationmsgshowon(scope.playlist[scope.playorder][i].connectmodel);
|
||||
|
|
|
@ -10,7 +10,6 @@ export function Textconfig(){
|
|||
if(scope.devicelist.length>0){
|
||||
scope.devicelist = [];
|
||||
}
|
||||
console.log(selectmodel.deviceType);
|
||||
if(selectmodel.deviceType == "DeviceSwitch"){
|
||||
initSwitchText(selectmodel);
|
||||
}
|
||||
|
@ -92,9 +91,6 @@ export function Textconfig(){
|
|||
}
|
||||
|
||||
|
||||
// if(part.text == null){
|
||||
// console.log(selectmodel.children[i].name);
|
||||
// }
|
||||
if(part.text){
|
||||
scope.devicelist.push(part);
|
||||
}
|
||||
|
@ -192,9 +188,6 @@ export function Textconfig(){
|
|||
part.msg = "用于机内外电缆连接,方便更换转辙机。";
|
||||
selectmodel.children[i].text = "二十位插接件";
|
||||
}
|
||||
// if(part.text == null){
|
||||
// console.log(selectmodel.children[i].name);
|
||||
// }
|
||||
if(part.text){
|
||||
scope.devicelist.push(part);
|
||||
}
|
||||
|
|
|
@ -36,7 +36,6 @@ export function ModelManager(){
|
|||
Promise.all(initlist).then((result) => {
|
||||
resolve("success"); //['成功了', 'success']
|
||||
}).catch((error) => {
|
||||
//console.log(error);
|
||||
});
|
||||
|
||||
});
|
||||
|
|
|
@ -70,7 +70,6 @@ export function ZzWw(dom,lessonData,lessonIndex) {
|
|||
animate();
|
||||
resolve("loadeend"); //['成功了', 'success']
|
||||
}).catch((error) => {
|
||||
//console.log(error);
|
||||
});
|
||||
|
||||
|
||||
|
|
|
@ -232,7 +232,6 @@ export default class SaidLamp extends Group {
|
|||
const signalButtons = [deviceType.PickArrow, deviceType.DepartArrow];
|
||||
if (signalButtons.includes(model._type)) {
|
||||
// if (model.runModel == 'S') { // 闭塞
|
||||
// console.log(model.runModel, model.runStatus, model.aspect, model.blockStatus, model._type, '88888888');
|
||||
// if (model.runStatus == 'NO') {
|
||||
// this.control && this.control.setControlColor(this.deviceStyle.fill);
|
||||
// } else {
|
||||
|
|
|
@ -1098,7 +1098,6 @@ export default class Station extends Group {
|
|||
if (deviceCode) {
|
||||
const device = store.getters['map/getDeviceByCode'](deviceCode);
|
||||
if (device.centralized) {
|
||||
// console.log(device.centralized, '666666666');
|
||||
this.stationText.setColor(this.style.Station.stationText.centralizedColor);
|
||||
} else {
|
||||
this.stationText.setColor(this.style.Station.stationText.noCentralizedColor);
|
||||
|
|
|
@ -28,8 +28,6 @@ class ESpecialCircle extends Group {
|
|||
}
|
||||
|
||||
setColor(color) {
|
||||
console.log(this.specialCircle);
|
||||
console.log(color);
|
||||
this.specialCircle.setStyle({ fill: color });
|
||||
}
|
||||
|
||||
|
|
|
@ -81,7 +81,6 @@ export default class TrainBody extends Group {
|
|||
textAlign: 'left',
|
||||
textVerticalAlign: 'top'
|
||||
});
|
||||
// console.log(model.fontSize, tripNumber.length - (style.Train.trainTarget.tripNumberPrefix.length || tripNumber.length), tripNumber, tripNumber.length - style.Train.trainTarget.tripNumberPrefix.length || tripNumber.length);
|
||||
this.textTrainTarget = new ETextName({
|
||||
zlevel: model.zlevel,
|
||||
z: model.z + 1,
|
||||
|
|
|
@ -117,7 +117,6 @@ export default {
|
|||
});
|
||||
},
|
||||
clickEvent(val) {
|
||||
// console.log(val, '--------', this.addModel.role, '========', document.getElementById(val));
|
||||
this.addModel.role && document.getElementById(this.addModel.role).setAttribute('style', 'background: #5F9EA0;color: #000; width:100%');
|
||||
this.addModel.role = val;
|
||||
document.getElementById(val).setAttribute('style', 'background: #000;color: #5F9EA0; width:100%');
|
||||
|
|
|
@ -128,7 +128,6 @@ export default {
|
|||
// if (elem && elem.hasOwnProperty('success')) {
|
||||
// if (elem.success) {
|
||||
// const operate = this.$store.state.training.operate;
|
||||
// console.log(elem);
|
||||
// elem.stationCodes.forEach(stationCode => {
|
||||
// const station = this.$store.getters['map/getDeviceByCode'](elem.stationCodes);
|
||||
// const newOperate = {
|
||||
|
|
|
@ -283,7 +283,7 @@ export default {
|
|||
this.$refs.ConfirmTip.doShow(operate);
|
||||
}
|
||||
}).catch(error => {
|
||||
console.log(error);
|
||||
console.error(error);
|
||||
});
|
||||
},
|
||||
closeMessage() {
|
||||
|
@ -304,7 +304,7 @@ export default {
|
|||
this.timeCountConfirm = -1; // 倒计时
|
||||
this.doClose();
|
||||
}).catch(error => {
|
||||
console.log(error);
|
||||
console.error(error);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
|
@ -257,10 +257,8 @@ export default {
|
|||
rcId: this.rcId
|
||||
};
|
||||
sendCommandNew(this.group, 'CTC_READ_DIS_COMMAND', data).then((res) => {
|
||||
console.log(res, '---res');
|
||||
// this.getReceiptData();
|
||||
}).catch(error => {
|
||||
console.log(error, '---已读命令error');
|
||||
});
|
||||
} else {
|
||||
// this.getReceiptData();
|
||||
|
@ -268,7 +266,6 @@ export default {
|
|||
},
|
||||
getReceiptData() {
|
||||
sendCommandNew(this.group, 'CTC_QUERY_RECEIPT_DIS_COMMAND', {cmdId: this.currentInfo.cmdId}).then((res) => {
|
||||
console.log(res, '---回执--');
|
||||
this.receiptList = res.data.receiptList;
|
||||
}).catch(error => {
|
||||
this.receiptList = [];
|
||||
|
@ -324,7 +321,6 @@ export default {
|
|||
this.$store.dispatch('trainingNew/next', operate).then(({ valid }) => {
|
||||
if (valid) {
|
||||
sendCommandNew(this.group, command, data).then((res) => {
|
||||
console.log(res, '---res');
|
||||
if (res.code == 200) {
|
||||
// this.searchCmd();
|
||||
} else {
|
||||
|
|
|
@ -233,7 +233,7 @@ export default {
|
|||
sendCommandNew(this.group, 'CTC_READ_DIS_COMMAND', data).then((res) => {
|
||||
console.log(res, '---res');
|
||||
}).catch(error => {
|
||||
console.log(error, '---已读命令error');
|
||||
console.error(error, '---已读命令error');
|
||||
});
|
||||
},
|
||||
signCmd(status) {
|
||||
|
@ -253,7 +253,6 @@ export default {
|
|||
this.$store.dispatch('trainingNew/next', operate).then(({ valid }) => {
|
||||
if (valid) {
|
||||
sendCommandNew(this.group, command, data).then((res) => {
|
||||
console.log(res, '---res');
|
||||
// this.$emit('changeSignedStatus', signInfo);
|
||||
this.doClose();
|
||||
}).catch(error => {
|
||||
|
@ -265,7 +264,6 @@ export default {
|
|||
searchCmd() {
|
||||
return new Promise((resolve, reject) => {
|
||||
sendCommandNew(this.group, 'CTC_QUERY_DIS_COMMAND', {holderType: 'Station', holderCode: this.getActiveUser.deviceCode}).then((res) => {
|
||||
console.log(res, '---res----');
|
||||
this.queryResData = res.data;
|
||||
resolve();
|
||||
}).catch(error => {
|
||||
|
|
|
@ -154,7 +154,7 @@ export default {
|
|||
}
|
||||
});
|
||||
}).catch(error => {
|
||||
console.log(error);
|
||||
console.error(error);
|
||||
});
|
||||
this.dialogShow = true;
|
||||
this.$nextTick(function () {
|
||||
|
|
|
@ -100,7 +100,6 @@ export default {
|
|||
commit() {
|
||||
this.$refs['form'].validate((valid) => {
|
||||
if (valid) {
|
||||
console.log(this.groupNumber, '----------');
|
||||
commitOperate(menuOperate.Train.driverStop, {groupNumber:this.groupNumber, eb: this.addModel.eb}, 3)
|
||||
.then(({ valid }) => {
|
||||
this.loading = false;
|
||||
|
|
|
@ -128,7 +128,6 @@ export default {
|
|||
// if (elem && elem.hasOwnProperty('success')) {
|
||||
// if (elem.success) {
|
||||
// const operate = this.$store.state.training.operate;
|
||||
// console.log(elem);
|
||||
// elem.stationCodes.forEach(stationCode => {
|
||||
// const station = this.$store.getters['map/getDeviceByCode'](elem.stationCodes);
|
||||
// const newOperate = {
|
||||
|
|
|
@ -119,7 +119,6 @@ export default {
|
|||
try {
|
||||
this.setMap(this.mapData, this.mapDevice);
|
||||
} catch (error) {
|
||||
console.log('[ERROR] ', error);
|
||||
}
|
||||
},
|
||||
// 设置地图
|
||||
|
|
|
@ -743,7 +743,6 @@ export default {
|
|||
return;
|
||||
}
|
||||
const buttonOperation = this.$store.state.menuOperation.buttonOperation;
|
||||
console.log(model._type, buttonOperation, this.commandTypeList.includes(model._type), this.commandTypeList);
|
||||
if (buttonOperation && this.commandTypeList.includes(model._type)) {
|
||||
if (buttonOperation === this.MixinCommand.totalCancel.button.operation) {
|
||||
this.handleTotalCancel(model);
|
||||
|
@ -856,7 +855,6 @@ export default {
|
|||
operate.over = true;
|
||||
operate.cmdType = CMD.Switch.CMD_SWITCH_BLOCK;
|
||||
} else if (this.operation === OperationEvent.Station.guideLock.button.operation) {
|
||||
console.log(this.selected, 'selected');
|
||||
operate.userOperationType = UserOperationType.LEFTCLICK;
|
||||
operate.over = true;
|
||||
operate.cmdType = this.selected.instance && this.selected.instance.guideLock ? CMD.Station.CMD_STATION_MASTER_UNLOCK : CMD.Station.CMD_STATION_MASTER_LOCK;
|
||||
|
|
|
@ -248,7 +248,6 @@ export default {
|
|||
}
|
||||
},
|
||||
handleT3MenuSelect(id) {
|
||||
console.log(id)
|
||||
this.closeMenus()
|
||||
const params = id.split('-')
|
||||
switch (params[0]) {
|
||||
|
|
|
@ -751,7 +751,6 @@ export default {
|
|||
loadData() {
|
||||
this.tableData = [];
|
||||
const railCtcRunplanInitMsg = copyAssign({}, this.$store.state.socket.railCtcRunplanInitMsg);
|
||||
console.log(railCtcRunplanInitMsg, 'railCtcRunplanInitMsg');
|
||||
this.tableData = Object.values(railCtcRunplanInitMsg).filter(data=>{
|
||||
if (data.departRunPlan) {
|
||||
// data.departRunPlan.planTime = this.coverTime(data.departRunPlan.planTime);
|
||||
|
@ -770,7 +769,6 @@ export default {
|
|||
: prev.arriveRunPlan ? (prev.arriveRunPlan.actualTime || prev.arriveRunPlan.planTime) : '00:00:00';
|
||||
const nextPlanTime = next.departRunPlan ? (next.departRunPlan.actualTime || next.departRunPlan.planTime)
|
||||
: next.arriveRunPlan ? (next.arriveRunPlan.actualTime || next.arriveRunPlan.planTime) : '00:00:00';
|
||||
// console.log(prevPlanTime, nextPlanTime, '66666666');
|
||||
// const nextPlanTime = next.departRunPlan ? next.departRunPlan.planTime : next.arriveRunPlan ? next.arriveRunPlan.planTime : '00:00:00';
|
||||
return new Date('2000-06-18 ' + prevPlanTime).getTime() - new Date('2000-06-18 ' + nextPlanTime).getTime();
|
||||
});
|
||||
|
@ -878,7 +876,6 @@ export default {
|
|||
// activeDepart.changeSectionCode = event;
|
||||
// document.getElementById('sendRunplan').classList.add('active');
|
||||
// }
|
||||
// console.log(event, this.tableData[index].departRunPlan.sectionCode, row.departRunPlan.sectionCode, '------');
|
||||
},
|
||||
// 修改接车股道
|
||||
changeArriveRunPlan(event, row, index) {
|
||||
|
@ -956,7 +953,6 @@ export default {
|
|||
this.currentRow = row;
|
||||
this.rpMenuPopShow = false;
|
||||
}
|
||||
console.log(this.currentRow);
|
||||
} else {
|
||||
this.currentRow = null;
|
||||
// this.rpMenuPopShow = false;
|
||||
|
|
|
@ -119,7 +119,7 @@ export default {
|
|||
try {
|
||||
this.setMap(this.mapData, this.mapDevice);
|
||||
} catch (error) {
|
||||
console.log('[ERROR] ', error);
|
||||
console.error('[ERROR] ', error);
|
||||
}
|
||||
},
|
||||
// 设置地图
|
||||
|
|
|
@ -730,7 +730,6 @@ export default {
|
|||
this.$store.dispatch('trainingNew/next', operate).then(({ valid, response }) => {
|
||||
this.clearOperate();
|
||||
}).catch((e) => {
|
||||
console.log(e, 'error');
|
||||
this.$refs.noticeInfo.doShow();
|
||||
this.clearOperate();
|
||||
});
|
||||
|
|
|
@ -106,7 +106,7 @@ export default {
|
|||
if (valid) {
|
||||
this.doClose();
|
||||
}
|
||||
}).catch((error) => { this.doClose(); this.$refs.noticeInfo.doShow(); console.log(error); });
|
||||
}).catch((error) => { this.doClose(); this.$refs.noticeInfo.doShow(); });
|
||||
},
|
||||
cancel() {
|
||||
const operate = {
|
||||
|
|
|
@ -443,7 +443,6 @@ export default {
|
|||
this.operation = operation;
|
||||
this.commandTypeList = commandTypeList;
|
||||
this.$store.dispatch('menuOperation/setButtonOperation', operation); // 按钮菜单是否被按下
|
||||
console.log(operation, this.$store.state.menuOperation.buttonOperation, '--------');
|
||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
// 判断是否需要 弹窗密码框
|
||||
if (operationList.includes(operation)) {
|
||||
|
@ -616,7 +615,6 @@ export default {
|
|||
cmdType: CMD.Signal.CMD_SIGNAL_HUMAN_RELEASE_ROUTE
|
||||
};
|
||||
// const signal = this.$store.getters['map/getDeviceByCode'](model.signalCode || model.code);
|
||||
console.log(model._type, model.type, '8888888');
|
||||
if (model._type === 'SignalButton' && model.type === 'PICK') {
|
||||
operate.param = { signalCode: model.signalCode, _COUNT: device.code };
|
||||
this.sendCommand(operate);
|
||||
|
|
|
@ -116,7 +116,6 @@ export default {
|
|||
},
|
||||
watch: {
|
||||
'$store.state.menuOperation.menuCount': function (val) {
|
||||
console.log(val, this.$store.getters['menuOperation/checkDialogIsOpen'](DeviceMenu.Section));
|
||||
if (this.$store.getters['menuOperation/checkDialogIsOpen'](DeviceMenu.Section)) {
|
||||
this.doShow(this.$store.state.menuOperation.menuPosition);
|
||||
} else {
|
||||
|
|
|
@ -128,7 +128,6 @@ export default {
|
|||
// if (elem && elem.hasOwnProperty('success')) {
|
||||
// if (elem.success) {
|
||||
// const operate = this.$store.state.training.operate;
|
||||
// console.log(elem);
|
||||
// elem.stationCodes.forEach(stationCode => {
|
||||
// const station = this.$store.getters['map/getDeviceByCode'](elem.stationCodes);
|
||||
// const newOperate = {
|
||||
|
|
|
@ -673,7 +673,6 @@ export default {
|
|||
activeDepart.changeSectionCode = event;
|
||||
document.getElementById('sendRunplan').classList.add('active');
|
||||
}
|
||||
// console.log(event, this.tableData[index].departRunPlan.sectionCode, row.departRunPlan.sectionCode, '------');
|
||||
},
|
||||
focusArriveRunPlan(event, row) {
|
||||
this.activeArriveRunPlan[row.code] = {sectionCode:event, code:row.code};
|
||||
|
@ -729,7 +728,6 @@ export default {
|
|||
this.currentRow = row;
|
||||
this.rpMenuPopShow = false;
|
||||
}
|
||||
console.log(this.currentRow);
|
||||
} else {
|
||||
this.currentRow = null;
|
||||
// this.rpMenuPopShow = false;
|
||||
|
|
|
@ -59,7 +59,6 @@ export default {
|
|||
},
|
||||
watch: {
|
||||
'$store.state.menuOperation.menuCount': function (val) {
|
||||
// console.log(this.buttonOperation, '***********');
|
||||
if (this.$store.getters['menuOperation/checkDialogIsOpen'](DeviceMenu.Section) && (!this.buttonOperation || this.$route.query.ctc)) {
|
||||
this.doShow(this.$store.state.menuOperation.menuPosition);
|
||||
} else {
|
||||
|
|
|
@ -256,7 +256,7 @@ export default {
|
|||
this.$refs.ConfirmTip.doShow(operate);
|
||||
}
|
||||
}).catch(error => {
|
||||
console.log(error);
|
||||
console.error(error);
|
||||
});
|
||||
},
|
||||
closeMessage() {
|
||||
|
@ -276,7 +276,7 @@ export default {
|
|||
this.timeCountConfirm = -1; // 倒计时
|
||||
this.doClose();
|
||||
}).catch(error => {
|
||||
console.log(error);
|
||||
console.error(error);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
|
@ -287,7 +287,6 @@ export default {
|
|||
const member = this.$store.state.training.memberList.find(member => member.type === 'STATION_SUPERVISOR' && member.deviceCode === stationCode);
|
||||
const data = [{userId: this.userId, memberId:member.id}];
|
||||
assignUsersPlayRoles(data, this.$route.query.group).then(() => {
|
||||
console.log('切换角色!');
|
||||
}).catch(e => {
|
||||
this.$message.error('切换车站失败!');
|
||||
});
|
||||
|
|
|
@ -111,7 +111,7 @@ export default {
|
|||
this.totalData = totalData;
|
||||
}).catch(error=>{
|
||||
this.loading = false;
|
||||
console.log(error);
|
||||
console.error(error);
|
||||
});
|
||||
},
|
||||
getTerminal(id) {
|
||||
|
|
|
@ -319,7 +319,6 @@ export default {
|
|||
const member = this.$store.state.training.memberList.find(member => member.type === 'STATION_SUPERVISOR' && member.deviceCode === stationCode);
|
||||
const data = [{userId: this.userId, memberId:member.id}];
|
||||
assignUsersPlayRoles(data, this.$route.query.group).then(() => {
|
||||
console.log('切换角色!');
|
||||
}).catch(e => {
|
||||
this.$message.error('切换车站失败!');
|
||||
});
|
||||
|
|
|
@ -111,7 +111,6 @@ export default {
|
|||
this.totalData = totalData;
|
||||
}).catch(error=>{
|
||||
this.loading = false;
|
||||
console.log(error);
|
||||
});
|
||||
},
|
||||
getTerminal(id) {
|
||||
|
|
|
@ -77,7 +77,6 @@ export default {
|
|||
},
|
||||
methods: {
|
||||
init() {
|
||||
console.log(123);
|
||||
document.getElementById(this.canvasId).oncontextmenu = function (e) {
|
||||
return false;
|
||||
};
|
||||
|
|
|
@ -74,7 +74,6 @@ export default {
|
|||
methods: {
|
||||
changeTrain(val) {
|
||||
const train = this.$store.getters['map/getDeviceByCode'](val);
|
||||
console.log('🚀 ~ file: trainDetail.vue:70 ~ changeTrain ~ val:', val, train);
|
||||
if (train) {
|
||||
this.initData(train);
|
||||
}
|
||||
|
|
|
@ -339,7 +339,6 @@ export default {
|
|||
},
|
||||
// 始端信号机点击
|
||||
handleCurrentChangeStar(val) {
|
||||
console.log('🚀 ~ file: routeCommand.vue:322 ~ handleCurrentChangeStar ~ val', val);
|
||||
if (!val) { return; }
|
||||
this.tempData = [];
|
||||
this.routeList.forEach(item => {
|
||||
|
|
|
@ -117,7 +117,6 @@ export default {
|
|||
this.$store.dispatch('training/emitTipFresh');
|
||||
},
|
||||
selectLine(val) {
|
||||
// console.log(val);
|
||||
this.selectShow = true;
|
||||
this.spanCol = 20;
|
||||
},
|
||||
|
|
|
@ -133,7 +133,6 @@ export default {
|
|||
this.$store.dispatch('training/emitTipFresh');
|
||||
},
|
||||
selectLine(val) {
|
||||
// console.log(val);
|
||||
this.selectShow = true;
|
||||
},
|
||||
commit() {
|
||||
|
|
|
@ -146,7 +146,6 @@ export default {
|
|||
// this.$refs.table.setCurrentRow(this.selected);
|
||||
}
|
||||
}).catch(() => {
|
||||
console.log();
|
||||
this.$refs.noticeInfo.doShow();
|
||||
});
|
||||
},
|
||||
|
|
|
@ -143,9 +143,6 @@ export default {
|
|||
});
|
||||
},
|
||||
methods: {
|
||||
// expandPath() {
|
||||
// console.log('展开进路预览');
|
||||
// },
|
||||
doShow(operate, activeName) {
|
||||
this.tableData = [];
|
||||
this.tableData = [...this.trainList];
|
||||
|
|
|
@ -14,7 +14,6 @@ class TransformHandle {
|
|||
}
|
||||
|
||||
checkVisible(view) {
|
||||
// console.log(view);
|
||||
return createBoundingRect(view).intersect(this.rect);
|
||||
}
|
||||
|
||||
|
|
|
@ -28,7 +28,6 @@ export function adapterByDevice(device, mapDevice) {
|
|||
it.type == 'TRANSMISSION' &&
|
||||
it.instance &&
|
||||
it.instance.isShowShape) {
|
||||
console.log(it.instance);
|
||||
return it;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -10,7 +10,6 @@ function loadDictionary() {
|
|||
that[field] = response.data;
|
||||
resolve(that[field]);
|
||||
}).catch(error => {
|
||||
console.log('获取字典失败:' + error.message);
|
||||
reject(error);
|
||||
});
|
||||
});
|
||||
|
|
|
@ -9,7 +9,6 @@ class ValidateHandler {
|
|||
let valid = true;
|
||||
if (Handler.getTrainingStart()) {
|
||||
valid = this.judgeTraining(operate);
|
||||
console.log(operate, valid, 'valid');
|
||||
if ((mode === ScriptMode.PRACTICE || mode === ScriptMode.TEACH) && operate.operation !== OperationEvent.Conversation.Chat.record.operation) {
|
||||
const rightMsg = {errMsg: LangStorage.getLang() === 'en' ? "Correct operation! That's great!" : '操作正确!真棒!', color: 'green'};
|
||||
const errorMsg = {errMsg: LangStorage.getLang() === 'en' ? 'operation mistake!' : '操作错误!', color: 'red'};
|
||||
|
@ -100,7 +99,6 @@ class ValidateHandler {
|
|||
store.dispatch('trainingNew/handleStepRecord', { type:'CONTINUE', stepOperation });
|
||||
Handler.judgeIsTextSendOperation();
|
||||
} else {
|
||||
console.log(operate, stepOperation, '----------');
|
||||
store.dispatch('trainingNew/handleStepRecord', { type:'ERROR', stepOperation });
|
||||
console.error('校验失败;');
|
||||
}
|
||||
|
|
|
@ -1316,7 +1316,6 @@ const map = {
|
|||
});
|
||||
const list = Object.values(dict);
|
||||
if (window.location.href.includes('/lineDesign/usermap/map/draw')) {
|
||||
console.log(state.mapDevice);
|
||||
handleOperation(state, list);
|
||||
}
|
||||
commit('mapRender', { devices: list });
|
||||
|
|
|
@ -7,7 +7,7 @@ export function openIndexedDB() {
|
|||
const indexedDBName = baseUrl.replace(/http.?:\/\/(.*)[\/|:].*/, '$1');
|
||||
const request = window.indexedDB.open(indexedDBName, 1);
|
||||
request.onerror = function (event) {
|
||||
console.log('数据库打开报错');
|
||||
console.error('数据库打开报错');
|
||||
};
|
||||
|
||||
request.onsuccess = function (event) {
|
||||
|
@ -25,8 +25,8 @@ export function awaitDbAddData(tableName, data) {
|
|||
return new Promise((resolve, reject) => {
|
||||
if (Vue.prototype.$db) {
|
||||
const request = Vue.prototype.$db.transaction([tableName], 'readwrite').objectStore(tableName).add(data);
|
||||
request.onsuccess = function(event) { console.log('数据写入成功'); resolve(request.result); };
|
||||
request.onerror = function(event) { console.log('数据写入失败'); reject(event); };
|
||||
request.onsuccess = function(event) { resolve(request.result); };
|
||||
request.onerror = function(event) { reject(event); };
|
||||
} else {
|
||||
openIndexedDB();
|
||||
reject({message: '数据库未打开!'});
|
||||
|
@ -48,7 +48,7 @@ export function dbAddData(tableName, data, params, successCallback, errorCallbac
|
|||
if (errorCallback && (typeof errorCallback === 'function')) {
|
||||
errorCallback(event, params);
|
||||
} else {
|
||||
console.log('数据写入失败');
|
||||
console.error('数据写入失败');
|
||||
}
|
||||
};
|
||||
} else {
|
||||
|
@ -64,7 +64,7 @@ export function awaitDbReadData(tableName, key) {
|
|||
if (Vue.prototype.$db) {
|
||||
const request = Vue.prototype.$db.transaction([tableName]).objectStore(tableName).get(key);
|
||||
request.onsuccess = function(event) { console.log('数据读取成功'); resolve(request.result); };
|
||||
request.onerror = function(event) { console.log('数据读取失败'); reject(event); };
|
||||
request.onerror = function(event) { console.error('数据读取失败'); reject(event); };
|
||||
} else {
|
||||
openIndexedDB();
|
||||
reject({message: '数据库未打开!'});
|
||||
|
@ -86,7 +86,7 @@ export function dbReadData(tableName, key, params, successCallback, errorCallbac
|
|||
if (errorCallback && (typeof errorCallback === 'function')) {
|
||||
errorCallback(event, params);
|
||||
} else {
|
||||
console.log('数据读取失败');
|
||||
console.error('数据读取失败');
|
||||
}
|
||||
};
|
||||
} else {
|
||||
|
@ -102,7 +102,7 @@ export function awaitDbUpdateData(tableName, data) {
|
|||
if (Vue.prototype.$db) {
|
||||
const request = Vue.prototype.$db.transaction([tableName], 'readwrite').objectStore(tableName).put(data);
|
||||
request.onsuccess = function(event) { console.log('数据更新成功'); resolve(request.result); };
|
||||
request.onerror = function(event) { console.log('数据更新失败'); reject(event); };
|
||||
request.onerror = function(event) { console.error('数据更新失败'); reject(event); };
|
||||
} else {
|
||||
openIndexedDB();
|
||||
reject({message: '数据库未打开!'});
|
||||
|
@ -124,7 +124,7 @@ export function dbUpdateData(tableName, data, params, successCallback, errorCall
|
|||
if (errorCallback && (typeof errorCallback === 'function')) {
|
||||
errorCallback(event, params);
|
||||
} else {
|
||||
console.log('数据更新失败');
|
||||
console.error('数据更新失败');
|
||||
}
|
||||
};
|
||||
} else {
|
||||
|
@ -140,7 +140,7 @@ export function awaitDbDeleteData(tableName, key) {
|
|||
if (Vue.prototype.$db) {
|
||||
const request = Vue.prototype.$db.transaction([tableName], 'readwrite').objectStore(tableName).delete(key);
|
||||
request.onsuccess = function(event) { console.log('数据删除成功'); resolve(request.result); };
|
||||
request.onerror = function(event) { console.log('数据删除失败'); reject(event); };
|
||||
request.onerror = function(event) { console.error('数据删除失败'); reject(event); };
|
||||
} else {
|
||||
openIndexedDB();
|
||||
reject({message: '数据库未打开!'});
|
||||
|
@ -162,7 +162,7 @@ export function dbDeleteData(tableName, key, params, successCallback, errorCallb
|
|||
if (errorCallback && (typeof errorCallback === 'function')) {
|
||||
errorCallback(event, params);
|
||||
} else {
|
||||
console.log('数据删除失败');
|
||||
console.error('数据删除失败');
|
||||
}
|
||||
};
|
||||
} else {
|
||||
|
|
|
@ -91,7 +91,6 @@ function handle(data) {
|
|||
store.dispatch('scriptRecord/updateSimulationPause', msg);
|
||||
break;
|
||||
case 'Simulation_Operation_Mode_Apply': // 模式转换消息
|
||||
console.log('模式转换消息', msg);
|
||||
store.dispatch('socket/operationModeApply', msg);
|
||||
break;
|
||||
case 'BROADCAST': // 升级通知消息
|
||||
|
|
|
@ -33,7 +33,7 @@ export default {
|
|||
this.$messageBox('license无效!');
|
||||
}
|
||||
} catch (error) {
|
||||
console.log(error);
|
||||
console.error(error);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue