修改转换数据计算
This commit is contained in:
parent
84dc26574b
commit
e805a97a6d
@ -266,8 +266,10 @@ export function RailList(){
|
|||||||
|
|
||||||
let num = scope.linkrail[linklist[j].code].lineleft.points.length-1;
|
let num = scope.linkrail[linklist[j].code].lineleft.points.length-1;
|
||||||
let lengthfacts = scope.linkrail[linklist[j].code].lineleft.points[num].x - scope.linkrail[linklist[j].code].lineleft.points[0].x;
|
let lengthfacts = scope.linkrail[linklist[j].code].lineleft.points[num].x - scope.linkrail[linklist[j].code].lineleft.points[0].x;
|
||||||
stop.direct1.percent = (standsdata[n].position.x-64-scope.linkrail[linklist[j].code].lineleft.points[0].x)/lengthfacts;
|
let directoffset1 = standsdata[n].position.x-64-scope.linkrail[linklist[j].code].lineleft.points[0].x;
|
||||||
stop.direct2.percent = (standsdata[n].position.x+64-scope.linkrail[linklist[j].code].lineleft.points[0].x)/lengthfacts;
|
let directoffset2 = standsdata[n].position.x+64-scope.linkrail[linklist[j].code].lineleft.points[0].x;
|
||||||
|
stop.direct1.percent = directoffset1/lengthfacts;
|
||||||
|
stop.direct2.percent = directoffset1/lengthfacts;
|
||||||
console.log(scope.linkrail[linklist[j].code]);
|
console.log(scope.linkrail[linklist[j].code]);
|
||||||
console.log("sectoffsetleft");
|
console.log("sectoffsetleft");
|
||||||
console.log(standsections[i].leftStopPointOffset);
|
console.log(standsections[i].leftStopPointOffset);
|
||||||
@ -291,28 +293,42 @@ export function RailList(){
|
|||||||
}else{
|
}else{
|
||||||
let num = scope.linkrail[linklist[j].code].lineleft.points.length-1;
|
let num = scope.linkrail[linklist[j].code].lineleft.points.length-1;
|
||||||
let lengthfacts = scope.linkrail[linklist[j].code].lineleft.points[num].x - scope.linkrail[linklist[j].code].lineleft.points[0].x;
|
let lengthfacts = scope.linkrail[linklist[j].code].lineleft.points[num].x - scope.linkrail[linklist[j].code].lineleft.points[0].x;
|
||||||
stop.direct1.percent = (standsdata[n].position.x-64-scope.linkrail[linklist[j].code].lineleft.points[0].x)/lengthfacts;
|
let directoffset1 = standsdata[n].position.x-64-scope.linkrail[linklist[j].code].lineleft.points[0].x;
|
||||||
stop.direct2.percent = (standsdata[n].position.x+64-scope.linkrail[linklist[j].code].lineleft.points[0].x)/lengthfacts;
|
let directoffset2 = standsdata[n].position.x+64-scope.linkrail[linklist[j].code].lineleft.points[0].x;
|
||||||
|
stop.direct1.percent = directoffset1/lengthfacts;
|
||||||
|
stop.direct2.percent = directoffset1/lengthfacts;
|
||||||
console.log(scope.linkrail[linklist[j].code]);
|
console.log(scope.linkrail[linklist[j].code]);
|
||||||
|
console.log(directoffset1);
|
||||||
|
console.log(directoffset1);
|
||||||
console.log("sectoffsetleft");
|
console.log("sectoffsetleft");
|
||||||
|
console.log(stop.direct2.percent);
|
||||||
|
console.log(scope.linkrail[linklist[j].code].lengthfact);
|
||||||
|
console.log(lengthfacts);
|
||||||
|
console.log("........................");
|
||||||
console.log(standsections[i].leftStopPointOffset);
|
console.log(standsections[i].leftStopPointOffset);
|
||||||
console.log(standsdata[n].position.x-64-scope.linkrail[linklist[j].code].lp.x);
|
console.log(standsdata[n].position.x-64-scope.linkrail[linklist[j].code].lineleft.points[0].x);
|
||||||
|
console.log("........................");
|
||||||
console.log(standsdata[n].position.x+64);
|
console.log(standsdata[n].position.x+64);
|
||||||
console.log(scope.linkrail[linklist[j].code].lineleft.getPointAt(stop.direct2.percent).x);
|
console.log(scope.linkrail[linklist[j].code].lineleft.getPointAt(stop.direct2.percent).x);
|
||||||
console.log("sectoffsetright");
|
console.log("sectoffsetright");
|
||||||
|
console.log(stop.direct1.percent);
|
||||||
|
console.log(scope.linkrail[linklist[j].code].lengthfact);
|
||||||
|
console.log(lengthfacts);
|
||||||
|
console.log("........................");
|
||||||
console.log(standsections[i].rightStopPointOffset);
|
console.log(standsections[i].rightStopPointOffset);
|
||||||
console.log(standsdata[n].position.x+64-scope.linkrail[linklist[j].code].lp.x);
|
console.log(standsdata[n].position.x-64-scope.linkrail[linklist[j].code].lineleft.points[0].x);
|
||||||
|
console.log("........................");
|
||||||
console.log(standsdata[n].position.x-64);
|
console.log(standsdata[n].position.x-64);
|
||||||
console.log(scope.linkrail[linklist[j].code].lineleft.getPointAt(stop.direct1.percent).x);
|
console.log(scope.linkrail[linklist[j].code].lineleft.getPointAt(stop.direct1.percent).x);
|
||||||
circle1.position.x = standsdata[n].position.x+64;
|
circle1.position.x = standsdata[n].position.x+64;
|
||||||
circle1.position.y = 5;
|
circle1.position.y = 5;
|
||||||
circle1.position.z = scope.linkrail[linklist[j].code].points[0].z+(standsdata[n].position.z-scope.linkrail[linklist[j].code].points[0].z)*2;
|
circle1.position.z = scope.linkrail[linklist[j].code].points[0].z+(standsdata[n].position.z-scope.linkrail[linklist[j].code].points[0].z)*2;
|
||||||
circle1.rotation.x = 0;
|
circle1.rotation.x = -Math.PI/2;
|
||||||
|
|
||||||
circle2.position.x = standsdata[n].position.x-64;
|
circle2.position.x = standsdata[n].position.x-64;
|
||||||
circle2.position.y = 5;
|
circle2.position.y = 5;
|
||||||
circle2.position.z = scope.linkrail[linklist[j].code].points[0].z;
|
circle2.position.z = scope.linkrail[linklist[j].code].points[0].z;
|
||||||
circle2.rotation.x = Math.PI;
|
circle2.rotation.x = -Math.PI/2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -3,11 +3,11 @@ export function getBaseUrl() {
|
|||||||
let BASE_API;
|
let BASE_API;
|
||||||
if (process.env.NODE_ENV === 'development') {
|
if (process.env.NODE_ENV === 'development') {
|
||||||
// BASE_API = 'https://joylink.club/jlcloud';
|
// BASE_API = 'https://joylink.club/jlcloud';
|
||||||
// BASE_API = 'https://test.joylink.club/jlcloud';
|
BASE_API = 'https://test.joylink.club/jlcloud';
|
||||||
// BASE_API = 'http://192.168.3.5:9000'; // 袁琪
|
// BASE_API = 'http://192.168.3.5:9000'; // 袁琪
|
||||||
// BASE_API = 'http://192.168.3.6:9000'; // 旭强
|
// BASE_API = 'http://192.168.3.6:9000'; // 旭强
|
||||||
// BASE_API = 'http://192.168.3.41:9000'; // 杜闪
|
// BASE_API = 'http://192.168.3.41:9000'; // 杜闪
|
||||||
BASE_API = 'http://192.168.3.82:9000'; // 杜康
|
// BASE_API = 'http://192.168.3.82:9000'; // 杜康
|
||||||
} else {
|
} else {
|
||||||
BASE_API = process.env.VUE_APP_BASE_API;
|
BASE_API = process.env.VUE_APP_BASE_API;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user