v2.0.0: fixed a small error with shadowcaster rounding

This commit is contained in:
Evan Debenham
2023-02-16 17:58:17 -05:00
parent d163767ab3
commit 508719bf25

View File

@@ -41,7 +41,7 @@ public final class ShadowCaster {
//testing the middle of a cell, so we use i + 0.5
rounding[i][j] = (int)Math.min(
j,
Math.round( (i + 0.5) * Math.cos( Math.asin( j / (i + 0.5) ))));
Math.round( i * Math.cos( Math.asin( j / (i + 0.5) ))));
}
}
}