Considerable cleanup. I think I also found the issue from the other day with values not loading from settings.

This commit is contained in:
Matthew Raymer
2023-07-06 18:12:21 +08:00
parent e3f58bd593
commit 754bced2a9
20 changed files with 657 additions and 79 deletions

View File

@@ -5,7 +5,7 @@ function createCamera() {
35, // fov = Field Of View
1, // aspect ratio (dummy value)
0.1, // near clipping plane
350 // far clipping plane
350, // far clipping plane
);
// move the camera back so we can view the scene

View File

@@ -62,7 +62,11 @@ export async function loadLandmarks(vue, world, scene, loop) {
// calculate positions for each claim, especially because some are random
const locations = landmarks.map((claim) =>
locForGive(claim, world.PLATFORM_SIZE, world.PLATFORM_EDGE_FOR_UNKNOWNS)
locForGive(
claim,
world.PLATFORM_SIZE,
world.PLATFORM_EDGE_FOR_UNKNOWNS,
),
);
// eslint-disable-next-line @typescript-eslint/no-this-alias
@@ -92,7 +96,7 @@ export async function loadLandmarks(vue, world, scene, loop) {
undefined,
function (error) {
console.error(error);
}
},
);
// calculate when lights shine on appearing claim area
@@ -120,7 +124,7 @@ export async function loadLandmarks(vue, world, scene, loop) {
.onComplete(() => {
scene.remove(light);
light.dispose();
})
}),
)
.start();
world.lights = [...world.lights, light];
@@ -129,18 +133,18 @@ export async function loadLandmarks(vue, world, scene, loop) {
console.error(
"Got bad server response status & data of",
resp.status,
resp.data
resp.data,
);
vue.setAlert(
"Error With Server",
"There was an error retrieving your claims from the server."
"There was an error retrieving your claims from the server.",
);
}
} catch (error) {
console.error("Got exception contacting server:", error);
vue.setAlert(
"Error With Server",
"There was a problem retrieving your claims from the server."
"There was a problem retrieving your claims from the server.",
);
}
}