修改三维设备模型道岔动画时间
@ -1,13 +1,13 @@
|
||||
export function Signallightload(lights) {
|
||||
|
||||
|
||||
settexture(lights, "red", 'https://test.joylink.club/oss/wx/signal/1.jpg');
|
||||
settexture(lights, "red", '../../static/model/device/signal/1.jpg');
|
||||
|
||||
settexture(lights, "yellow", 'https://test.joylink.club/oss/wx/signal/2.jpg');
|
||||
settexture(lights, "yellow", '../../static/model/device/signal/2.jpg');
|
||||
|
||||
settexture(lights, "green", 'https://test.joylink.club/oss/wx/signal/3.jpg');
|
||||
settexture(lights, "green", '../../static/model/device/signal/3.jpg');
|
||||
|
||||
settexture(lights, "black", 'https://test.joylink.club/oss/wx/signal/4.jpg');
|
||||
settexture(lights, "black", '../../static/model/device/signal/4.jpg');
|
||||
}
|
||||
|
||||
function settexture(lights, name, textureurl) {
|
||||
|
@ -5,7 +5,7 @@ var Staticmodel = {
|
||||
deviceType: "Switch",
|
||||
type: "fuzhou",
|
||||
picUrl: "",
|
||||
assetUrl: "./../static/model/device/switch.FBX"
|
||||
assetUrl: "./../static/model/device/switch/switch.FBX"
|
||||
},//"https://joylink.club/oss/wx/switch/switch.FBX"
|
||||
//../../static/model/device/switch.FBX
|
||||
Signal: {
|
||||
@ -14,7 +14,7 @@ var Staticmodel = {
|
||||
deviceType: "Signal",
|
||||
type: "low",
|
||||
picUrl: "",
|
||||
assetUrl: "../../static/model/device/signal.FBX"
|
||||
assetUrl: "../../static/model/device/signal/signal.FBX"
|
||||
},
|
||||
stationstand: {
|
||||
id: "3",
|
||||
@ -22,7 +22,7 @@ var Staticmodel = {
|
||||
deviceType: "stationstand",
|
||||
type: "low",
|
||||
picUrl: "",
|
||||
assetUrl: "../../static/model/device/stationstand.FBX"
|
||||
assetUrl: "../../static/model/device/stationstand/stationstand.FBX"
|
||||
//https://joylink.club/oss/wx/stationstand/stationstand.FBX
|
||||
//../../static/model/device/stationstand.FBX
|
||||
|
||||
|
@ -168,6 +168,7 @@ export function Jl3ddeviceNew(dom,group,token) {
|
||||
scope.modelmanager.switchmodel.normalPosition = "0";
|
||||
scope.showmodel = scope.modelmanager.switchmodel.mesh;
|
||||
// scope.scene.add(scope.showmodel);
|
||||
console.log(data.normalPosition);
|
||||
if (data.normalPosition == "0") {
|
||||
scope.modelmanager.switchmodel.normalPosition = "0";
|
||||
scope.modelmanager.switchmodel.action.reset();
|
||||
@ -178,6 +179,7 @@ export function Jl3ddeviceNew(dom,group,token) {
|
||||
} else if (data.normalPosition == "1") {
|
||||
scope.modelmanager.switchmodel.normalPosition = "1";
|
||||
scope.modelmanager.switchmodel.action.reset();
|
||||
|
||||
scope.modelmanager.switchmodel.action.time = scope.modelmanager.switchmodel.action._clip.duration;
|
||||
scope.modelmanager.switchmodel.action.timeScale = 1;
|
||||
scope.modelmanager.switchmodel.action.play();
|
||||
@ -201,20 +203,20 @@ export function Jl3ddeviceNew(dom,group,token) {
|
||||
}
|
||||
|
||||
this.updateaction = function (data) {
|
||||
|
||||
console.log(data);
|
||||
if (data.type == "SWITCH") {
|
||||
if (data.normal == "0") {
|
||||
scope.modelmanager.switchmodel.normalPosition = "0";
|
||||
scope.modelmanager.switchmodel.action.reset();
|
||||
scope.modelmanager.switchmodel.action.time = 0;
|
||||
scope.modelmanager.switchmodel.action.timeScale = -1;
|
||||
scope.modelmanager.switchmodel.action.timeScale = 1;
|
||||
scope.modelmanager.switchmodel.action.play();
|
||||
|
||||
} else if (data.normal == "1") {
|
||||
scope.modelmanager.switchmodel.normalPosition = "1";
|
||||
scope.modelmanager.switchmodel.action.reset();
|
||||
scope.modelmanager.switchmodel.action.time = scope.modelmanager.switchmodel.action._clip.duration;
|
||||
scope.modelmanager.switchmodel.action.timeScale = 1;
|
||||
scope.modelmanager.switchmodel.action.timeScale = -1;
|
||||
scope.modelmanager.switchmodel.action.play();
|
||||
|
||||
}
|
||||
@ -271,19 +273,20 @@ export function Jl3ddeviceNew(dom,group,token) {
|
||||
}
|
||||
|
||||
function initstatus(data) {
|
||||
|
||||
console.log(data);
|
||||
if (data._type == "Switch") {
|
||||
if (data.normalPosition == "0") {
|
||||
scope.modelmanager.switchmodel.normalPosition = "0";
|
||||
scope.modelmanager.switchmodel.action.reset();
|
||||
scope.modelmanager.switchmodel.action.time = 0;
|
||||
scope.modelmanager.switchmodel.action.timeScale = -1;
|
||||
scope.modelmanager.switchmodel.action.time = scope.modelmanager.switchmodel.action._clip.duration;
|
||||
scope.modelmanager.switchmodel.action.timeScale = 1;
|
||||
|
||||
scope.modelmanager.switchmodel.action.play();
|
||||
} else if (data.normalPosition == "1") {
|
||||
scope.modelmanager.switchmodel.normalPosition = "1";
|
||||
scope.modelmanager.switchmodel.action.reset();
|
||||
scope.modelmanager.switchmodel.action.time = scope.modelmanager.switchmodel.action._clip.duration;
|
||||
scope.modelmanager.switchmodel.action.timeScale = 1;
|
||||
scope.modelmanager.switchmodel.action.time = 0;
|
||||
scope.modelmanager.switchmodel.action.timeScale = -1;
|
||||
scope.modelmanager.switchmodel.action.play();
|
||||
}
|
||||
}
|
||||
|
BIN
static/model/device/signal/1.jpg
Normal file
After Width: | Height: | Size: 26 KiB |
BIN
static/model/device/signal/2.jpg
Normal file
After Width: | Height: | Size: 27 KiB |
BIN
static/model/device/signal/3.jpg
Normal file
After Width: | Height: | Size: 24 KiB |
BIN
static/model/device/signal/4.jpg
Normal file
After Width: | Height: | Size: 8.3 KiB |
BIN
static/model/device/signal/5.jpg
Normal file
After Width: | Height: | Size: 17 KiB |
BIN
static/model/device/signal/signal.FBX
Normal file
BIN
static/model/device/stationstand/stationstand.bak.FBX
Normal file
BIN
static/model/device/stationstand/zt001.png
Normal file
After Width: | Height: | Size: 21 KiB |
BIN
static/model/device/stationstand/zt005.png
Normal file
After Width: | Height: | Size: 375 KiB |
BIN
static/model/device/stationstand/zt007.png
Normal file
After Width: | Height: | Size: 5.4 KiB |
BIN
static/model/device/stationstand/zt008.png
Normal file
After Width: | Height: | Size: 19 KiB |
BIN
static/model/device/switch/011.jpg
Normal file
After Width: | Height: | Size: 17 KiB |
BIN
static/model/device/switch/012.jpg
Normal file
After Width: | Height: | Size: 16 KiB |
BIN
static/model/device/switch/013.jpg
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
static/model/device/switch/014.jpg
Normal file
After Width: | Height: | Size: 21 KiB |
BIN
static/model/device/switch/015.jpg
Normal file
After Width: | Height: | Size: 21 KiB |
BIN
static/model/device/switch/016.jpg
Normal file
After Width: | Height: | Size: 22 KiB |
BIN
static/model/device/switch/017.jpg
Normal file
After Width: | Height: | Size: 9.2 KiB |
BIN
static/model/device/switch/020.jpg
Normal file
After Width: | Height: | Size: 19 KiB |
BIN
static/model/device/switch/021.jpg
Normal file
After Width: | Height: | Size: 17 KiB |
BIN
static/model/device/switch/022.jpg
Normal file
After Width: | Height: | Size: 9.3 KiB |
BIN
static/model/device/switch/024.jpg
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
static/model/device/switch/switch.bak.FBX
Normal file
BIN
static/model/device/switch/z025.jpg
Normal file
After Width: | Height: | Size: 24 KiB |