Current Version(without the save changes)

This commit is contained in:
StempunkDev 2023-07-28 15:39:34 +02:00
parent 0936a03c60
commit 104fd9b8d5
5 changed files with 14 additions and 17 deletions

16
main.js
View file

@ -184,7 +184,8 @@ let options = {
pinNotes: false,
showMFCGMap: true,
winds: [225, 45, 225, 315, 135, 315],
SouthPoleTemperature: 0,
tempNorthPole: 0,
tempSouthPole: 0,
stateLabelsMode: "auto"
};
let mapCoordinates = {}; // map coordinates on globe
@ -1009,13 +1010,14 @@ function calculateTemperatures() {
TIME && console.time("calculateTemperatures");
const cells = grid.cells;
cells.temp = new Int8Array(cells.i.length); // temperature array
const tEq = +temperatureEquatorInput.value;
const tNPole = +temperatureNorthPoleInput.value;
//TODO Find proper delta to calculate
const tSPole = +temperatureSouthPoleInput.value;
const tNDelta = tEq - tNPole;
const tSDelta = tEq - tSPole;
const tNorthPole = +temperatureNorthPoleInput.value;
const tSouthPole = +temperatureSouthPoleInput.value;
//Update Settings to match the slider(there may be a better solution)
options.tempSouthPole = +tSouthPole;
options.tempNorthPole = +tNorthPole;
const tNDelta = tEq - tNorthPole;
const tSDelta = tEq - tSouthPole;
const int = d3.easePolyInOut.exponent(0.5); // interpolation function
d3.range(0, cells.i.length, grid.cellsX).forEach(function (r) {