diff --git a/skycraft/index.ts b/skycraft/index.ts index 912e87c..9ad907a 100644 --- a/skycraft/index.ts +++ b/skycraft/index.ts @@ -363,7 +363,8 @@ async function main() { // [ ] landing // [ ] huge planets // [x] lighting - // [ ] better lighting + // [x] better lighting + // [ ] betterer lighting // [x] optimize geometry generation const modelPromise = loadObjModel('spaceship.obj'); diff --git a/skycraft/orbit.ts b/skycraft/orbit.ts index 5c7837f..5d85620 100644 --- a/skycraft/orbit.ts +++ b/skycraft/orbit.ts @@ -181,7 +181,7 @@ export function getCartesianState(orbit: Orbit, mu: number, time: number) { // Newton's method var E2 = 0; - var E = orbit.lastE || M; + var E = M; let iterations = 0; // a clever guess? https://link.springer.com/article/10.1023/A:1008200607490 // doesn't work at all.