1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-12-25 01:20:37 +00:00

ray:: fixed mirrors in product when cells have different degrees

This commit is contained in:
Zeno Rogue 2021-07-09 20:35:44 +02:00
parent f3fec9434a
commit 4799f7c5f7

View File

@ -1368,7 +1368,7 @@ void enable_raycaster() {
" }\n"; " }\n";
if(use_reflect) { if(use_reflect) {
if(prod) fmain += "if(reflect && which >= "+its(deg-2)+") { zspeed = -zspeed; continue; }\n"; if(prod) fmain += "if(reflect && which >= sides-2) { zspeed = -zspeed; continue; }\n";
if(hyperbolic && bt::in()) fmain += if(hyperbolic && bt::in()) fmain +=
"if(reflect && (which < "+its(flat1)+" || which >= "+its(flat2)+")) {\n" "if(reflect && (which < "+its(flat1)+" || which >= "+its(flat2)+")) {\n"
" mediump float x = -log(position.w - position.x);\n" " mediump float x = -log(position.w - position.x);\n"