mirror of
https://github.com/exoticorn/microw8.git
synced 2026-01-20 19:26:43 +01:00
saved 10 bytes by chosing better float constants
This commit is contained in:
@@ -18,9 +18,9 @@ export fn upd() {
|
||||
let y: i32;
|
||||
let inline zero = 0.0;
|
||||
|
||||
let lazy control_speed = 0.03;
|
||||
s = s + 0.1 - (f + control_speed) * btn(4 <| cls(4)) as f32;
|
||||
f = f * 0.7;
|
||||
let lazy control_speed = 0.03125;
|
||||
s = s + 0.125 - (f + control_speed) * btn(4 <| cls(4)) as f32;
|
||||
f = f * 0.75;
|
||||
|
||||
printInt(pz);
|
||||
|
||||
@@ -48,7 +48,7 @@ export fn upd() {
|
||||
}
|
||||
py = zero;
|
||||
s = zero;
|
||||
f = 0.8;
|
||||
f = 0.75;
|
||||
}
|
||||
|
||||
branch_if y < 240: lines;
|
||||
|
||||
Reference in New Issue
Block a user