修复三维驾驶切车后未复位模型
This commit is contained in:
parent
79af11beb6
commit
ed00bc646b
@ -56,6 +56,7 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
||||
}
|
||||
|
||||
if(data.type == "Train_Position_3D"){
|
||||
|
||||
otherTrainRun(data.body);
|
||||
return;
|
||||
}
|
||||
@ -220,13 +221,17 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
||||
}else{
|
||||
|
||||
for(let i=0,leni=data.length;i<leni;i++){
|
||||
let updateTrain = trainlisttest.otherTrainList[data[i].code];
|
||||
|
||||
if(data[i].code != trainmodel.code){
|
||||
let updateTrain = trainlisttest.otherTrainList[data[i].code];
|
||||
|
||||
otherTrainUpdate(data[i],updateTrain);
|
||||
}else{
|
||||
trainlisttest.otherTrainList[data[i].code].position.x = -99999;
|
||||
updateTrain.position.x = -99999;
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -240,7 +245,6 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
||||
// console.log(data);
|
||||
// }
|
||||
|
||||
if(updateTrainModel.code != trainmodel.code){
|
||||
if(data.section != updateTrainModel.nowsection){
|
||||
updateTrainModel.nowsection = data.section;
|
||||
updateTrainModel.curve = rails.sectionrail[data.section].lineleft;
|
||||
@ -397,7 +401,7 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -407,7 +411,12 @@ export function Jl3dDrivingNew(mixers,updatemmi,sound,translation,routegroup,dri
|
||||
// if(data.code = "336"){
|
||||
// console.log(data);
|
||||
// }
|
||||
|
||||
if(data.code != trainmodel.code){
|
||||
if(trainlisttest.otherTrainList[trainmodel.code] && trainmodel.code){
|
||||
trainlisttest.otherTrainList[trainmodel.code].offset = 0;
|
||||
}
|
||||
|
||||
trainmodel.code = data.code;
|
||||
trainmodel.nowcode = data.code;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user