Skip to content

Commit b858e8a

Browse files
authored
Merge pull request #81 from tilak-io/remove-offsets-in-global-position
Remove offsets in global position
2 parents 6d71be3 + cb898ac commit b858e8a

File tree

2 files changed

+5
-8
lines changed

2 files changed

+5
-8
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "tiplot",
3-
"version": "1.2.1",
3+
"version": "1.2.2",
44
"private": true,
55
"homepage": "./",
66
"proxy": "http://localhost:5000",

src/controllers/Entity.js

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ export default class Entity {
122122
const loader = new GLTFLoader();
123123
loader.load(
124124
`http://localhost:${PORT}/model`,
125-
function (gltf) {
125+
function(gltf) {
126126
instance.mesh = gltf.scene;
127127
instance.mesh.children[0].children[0].material.transparent = true;
128128
instance.mesh.children[0].children[0].material.opacity = instance.alpha;
@@ -137,7 +137,7 @@ export default class Entity {
137137
scene.add(instance.mesh);
138138
},
139139
undefined,
140-
function (error) {
140+
function(error) {
141141
console.log(error);
142142
console.log("failed to load drone, setting up default cube");
143143
const geometry = new THREE.BoxGeometry(2, 0.5, 0.3);
@@ -161,11 +161,8 @@ export default class Entity {
161161
this.ref_y = e.props[0].y;
162162
this.ref_z = e.props[0].z;
163163
} else {
164-
const [x, y] = getXY(e.props[0].longitude, e.props[0].lattitude);
165-
// const z = -e.props[0].altitude;
166-
this.ref_x = x;
167-
this.ref_y = y;
168-
// this.ref_z = z;
164+
this.ref_x = 0;
165+
this.ref_y = 0;
169166
this.ref_z = 0;
170167
}
171168
}

0 commit comments

Comments
 (0)