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

moved mouse-line from rug to drawMarkers

This commit is contained in:
Zeno Rogue 2020-12-30 03:26:01 +01:00
parent f7ba6108b2
commit 8a63307ed5
2 changed files with 14 additions and 4 deletions

View File

@ -4174,9 +4174,23 @@ EX cell *forwardcell() {
EX bool draw_centerover = true;
EX bool should_draw_mouse_cursor() {
if(!mousing || inHighQual) return false;
if(outofmap(mouseh.h)) return false;
if(rug::rugged && !rug::renderonce) return true;
if(vrhr::state) return true;
return false;
}
EX void drawMarkers() {
if(!(cmode & sm::NORMAL)) return;
if(should_draw_mouse_cursor()) {
for(int i=0; i<numplayers(); i++) if(multi::playerActive(i)) {
queueline(ggmatrix(playerpos(i)) * (WDIM == 2 && GDIM == 3 ? zpush0(cgi.WALL) : C0), mouseh, 0xFF00FF, grid_prec() + 1);
}
}
callhooks(hooks_markers);
#if CAP_SHAPES

View File

@ -1040,10 +1040,6 @@ EX void prepareTexture() {
#endif
drawthemap();
if(mousing && !renderonce && !inHighQual) {
for(int i=0; i<numplayers(); i++) if(multi::playerActive(i))
queueline(tC0(ggmatrix(playerpos(i))), mouseh, 0xFF00FF, 8 + vid.linequality);
}
if(finger_center) {
shiftmatrix V = rgpushxto0(finger_center->h);
queuestr(V, 0.5, "X", 0xFFFFFFFF, 2);