mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-11-27 14:37:16 +00:00
improvements to the mobile compass: can be used in modes other than MOVE (long click to switch mode to MOVE anyway); better arrow scaling
This commit is contained in:
parent
5b41f5d157
commit
b502b7025d
@ -878,8 +878,8 @@ void gmodekeys(int sym, int uni) {
|
||||
}
|
||||
|
||||
bool haveMobileCompass() {
|
||||
#if CAP_MOBILE
|
||||
if(andmode || useRangedOrb) return false;
|
||||
#if ISMOBILE
|
||||
if(longclick) return false;
|
||||
#else
|
||||
if(forcetarget) return false;
|
||||
#endif
|
||||
|
@ -5522,10 +5522,6 @@ void drawfullmap() {
|
||||
profile_stop(2);
|
||||
}
|
||||
|
||||
#ifdef ISMOBILE
|
||||
int andmode;
|
||||
#endif
|
||||
|
||||
void gamescreen(int _darken) {
|
||||
|
||||
if(ISMOBILE && (cmode & sm::SIDE)) {
|
||||
@ -5566,7 +5562,7 @@ void gamescreen(int _darken) {
|
||||
drawCircle(xfire, yb, rad/2, 0xFF0000FF);
|
||||
}
|
||||
else {
|
||||
if(andmode != 0) displayabutton(-1, +1, XLAT("MOVE"), andmode == 0 ? BTON : BTOFF);
|
||||
if(!haveMobileCompass()) displayabutton(-1, +1, XLAT(andmode == 0 && useRangedOrb ? "FIRE" : "MOVE"), andmode == 0 ? BTON : BTOFF);
|
||||
displayabutton(+1, +1, rug::rugged ? "RUG" : XLAT(andmode == 1 ? "BACK" : "DRAG"), andmode == 1 ? BTON : BTOFF);
|
||||
}
|
||||
displayabutton(-1, -1, XLAT("INFO"), andmode == 12 ? BTON : BTOFF);
|
||||
|
2
hud.cpp
2
hud.cpp
@ -317,7 +317,7 @@ void drawMobileArrow(cell *c, transmatrix V) {
|
||||
|
||||
poly_outline = OUTLINE_DEFAULT;
|
||||
// transmatrix m2 = Id;
|
||||
ld scale = vid.mobilecompasssize * 7;
|
||||
ld scale = vid.mobilecompasssize * 5;
|
||||
// m2[0][0] = scale; m2[1][1] = scale; m2[2][2] = 1;
|
||||
|
||||
transmatrix Centered = rgpushxto0(tC0(cwtV * sphereflip));
|
||||
|
3
hyper.h
3
hyper.h
@ -1478,6 +1478,7 @@ extern bool timerghost;
|
||||
#define displayfrZH dialog::zoom::displayfr_highlight
|
||||
#else
|
||||
#define displayfrZ displayfr
|
||||
#define displayfrZH dialog::zoom::displayfr_highlight
|
||||
#endif
|
||||
|
||||
namespace dialog {
|
||||
@ -2225,6 +2226,8 @@ int gl_width(int size, const char *s);
|
||||
|
||||
#ifdef ISMOBILE
|
||||
extern int andmode;
|
||||
extern bool longclick;
|
||||
extern bool useRangedOrb;
|
||||
#endif
|
||||
|
||||
void addaura(const hyperpoint& h, int col, int fd);
|
||||
|
Loading…
Reference in New Issue
Block a user