mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-12-24 01:00:25 +00:00
ray:: fixed the interaction of m_via_texture and changing gms_array_size
This commit is contained in:
parent
2c59bb3004
commit
cf7d19c775
@ -1714,6 +1714,7 @@ struct raycast_map {
|
|||||||
}
|
}
|
||||||
|
|
||||||
bool gms_exceeded() {
|
bool gms_exceeded() {
|
||||||
|
if(m_via_texture) return false;
|
||||||
return isize(ms) > gms_array_size;
|
return isize(ms) > gms_array_size;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1966,10 +1967,19 @@ EX void cast() {
|
|||||||
if(rmap->need_to_create(cs)) {
|
if(rmap->need_to_create(cs)) {
|
||||||
rmap->create_all(cs);
|
rmap->create_all(cs);
|
||||||
if(rmap->gms_exceeded()) {
|
if(rmap->gms_exceeded()) {
|
||||||
gms_array_size = isize(rmap->ms);
|
if(isize(rmap->ms) > gms_limit || can_via_texture) {
|
||||||
println(hlog, "changing gms_array_size to ", gms_array_size);
|
m_via_texture = true;
|
||||||
reset_raycaster();
|
wall_via_texture = true;
|
||||||
cast();
|
println(hlog, "enabling m_via_texture");
|
||||||
|
reset_raycaster();
|
||||||
|
cast();
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
gms_array_size = isize(rmap->ms);
|
||||||
|
println(hlog, "changing gms_array_size to ", gms_array_size);
|
||||||
|
reset_raycaster();
|
||||||
|
cast();
|
||||||
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
rmap->assign_uniforms(&*o);
|
rmap->assign_uniforms(&*o);
|
||||||
|
Loading…
Reference in New Issue
Block a user