fix visual bug of ms per frame and ship departing from wrong planet
This commit is contained in:
parent
814f0fb0ff
commit
d6ff2ea1e9
3 changed files with 4 additions and 4 deletions
|
@ -55,8 +55,8 @@ impl Circle {
|
|||
x = x3 - (r.powi(2)-(q/2.0).powi(2)).sqrt() * (y1-y2)/q;
|
||||
y = y3 - (r.powi(2)-(q/2.0).powi(2)).sqrt() * (x2-x1)/q;
|
||||
|
||||
a2 = (y - y1).atan2(x - x1);
|
||||
a1 = (y - y2).atan2(x - x2);
|
||||
a1 = (y - y1).atan2(x - x1);
|
||||
a2 = (y - y2).atan2(x - x2);
|
||||
}
|
||||
|
||||
let distance = q.ceil() as usize + 1;
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
</div>
|
||||
<div>
|
||||
<span>Ms per frame: </span>
|
||||
<input type="number" id="speed" value="500">
|
||||
<input type="number" id="speed" value="100">
|
||||
</div>
|
||||
<div class="slidecontainer">
|
||||
<input type="range" min="0" max="1" value="1" class="slider" id="turnSlider">
|
||||
|
|
|
@ -51,7 +51,7 @@ const RESOLUTION = [CANVAS.width, CANVAS.height];
|
|||
|
||||
const GL = CANVAS.getContext("webgl");
|
||||
|
||||
var ms_per_frame = 100;
|
||||
var ms_per_frame = parseInt(SPEED.value);
|
||||
|
||||
resizeCanvasToDisplaySize(CANVAS);
|
||||
|
||||
|
|
Loading…
Reference in a new issue