mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-02-02 20:29:17 +00:00
removed DOSHMUP
This commit is contained in:
parent
6303b8033b
commit
f721c243d2
@ -465,6 +465,8 @@ void resize_screen_to(int x, int y) {
|
|||||||
setvideomode();
|
setvideomode();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int timetowait;
|
||||||
|
|
||||||
void mainloopiter() {
|
void mainloopiter() {
|
||||||
|
|
||||||
DEBB(DF_GRAPH, (debugfile,"main loop\n"));
|
DEBB(DF_GRAPH, (debugfile,"main loop\n"));
|
||||||
@ -481,17 +483,16 @@ void mainloopiter() {
|
|||||||
ticks = SDL_GetTicks();
|
ticks = SDL_GetTicks();
|
||||||
callhooks(hooks_fixticks);
|
callhooks(hooks_fixticks);
|
||||||
|
|
||||||
int timetowait = lastt + 1000 / cframelimit - ticks;
|
timetowait = lastt + 1000 / cframelimit - ticks;
|
||||||
|
|
||||||
cframelimit = vid.framelimit;
|
cframelimit = vid.framelimit;
|
||||||
if(outoffocus && cframelimit > 10) cframelimit = 10;
|
if(outoffocus && cframelimit > 10) cframelimit = 10;
|
||||||
|
|
||||||
bool normal = cmode & sm::NORMAL;
|
bool normal = cmode & sm::NORMAL;
|
||||||
|
|
||||||
if(DOSHMUP && normal)
|
shmup::turn(ticks - lastt);
|
||||||
timetowait = 0, shmup::turn(ticks - lastt);
|
|
||||||
|
|
||||||
if(!DOSHMUP && (multi::alwaysuse || multi::players > 1) && normal)
|
if(!shmup::on && (multi::alwaysuse || multi::players > 1) && normal)
|
||||||
timetowait = 0, multi::handleMulti(ticks - lastt);
|
timetowait = 0, multi::handleMulti(ticks - lastt);
|
||||||
|
|
||||||
if(vid.sspeed >= 5 && gmatrix.count(cwt.c) && !elliptic) {
|
if(vid.sspeed >= 5 && gmatrix.count(cwt.c) && !elliptic) {
|
||||||
|
@ -3740,10 +3740,7 @@ void drawcell(cell *c, transmatrix V, int spinv, bool mirrored) {
|
|||||||
|
|
||||||
const transmatrix *Vboat = &(*Vdp);
|
const transmatrix *Vboat = &(*Vdp);
|
||||||
|
|
||||||
if(DOSHMUP) {
|
shmup::drawMonster(V, c, Vboat, Vboat0, Vdp);
|
||||||
ld zlev = -geom3::factor_to_lev(zlevel(tC0((*Vdp))));
|
|
||||||
shmup::drawMonster(V, c, Vboat, Vboat0, zlev);
|
|
||||||
}
|
|
||||||
|
|
||||||
poly_outline = OUTLINE_DEFAULT;
|
poly_outline = OUTLINE_DEFAULT;
|
||||||
|
|
||||||
|
8
hyper.h
8
hyper.h
@ -2083,12 +2083,6 @@ int textwidth(int siz, const string &str);
|
|||||||
extern bool gtouched, mousepressed, mousemoved, actonrelease;
|
extern bool gtouched, mousepressed, mousemoved, actonrelease;
|
||||||
extern bool inslider;
|
extern bool inslider;
|
||||||
|
|
||||||
#if CAP_ROGUEVIZ
|
|
||||||
#define DOSHMUP (shmup::on || rogueviz::on)
|
|
||||||
#else
|
|
||||||
#define DOSHMUP shmup::on
|
|
||||||
#endif
|
|
||||||
|
|
||||||
extern bool outoffocus;
|
extern bool outoffocus;
|
||||||
extern int frames;
|
extern int frames;
|
||||||
extern transmatrix playerV;
|
extern transmatrix playerV;
|
||||||
@ -3600,4 +3594,6 @@ struct pathdata {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
extern int timetowait;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -2874,6 +2874,8 @@ hookset<bool(int)> *hooks_turn;
|
|||||||
void turn(int delta) {
|
void turn(int delta) {
|
||||||
|
|
||||||
if(callhandlers(false, hooks_turn, delta)) return;
|
if(callhandlers(false, hooks_turn, delta)) return;
|
||||||
|
if(!shmup::on) return;
|
||||||
|
timetowait = 0;
|
||||||
|
|
||||||
passive_switch = (gold() & 1) ? moSwitch1 : moSwitch2;
|
passive_switch = (gold() & 1) ? moSwitch1 : moSwitch2;
|
||||||
lmousetarget = NULL;
|
lmousetarget = NULL;
|
||||||
@ -3147,11 +3149,14 @@ bool boatAt(cell *c) {
|
|||||||
|
|
||||||
hookset<bool(const transmatrix&, cell*, shmup::monster*)> *hooks_draw;
|
hookset<bool(const transmatrix&, cell*, shmup::monster*)> *hooks_draw;
|
||||||
|
|
||||||
bool drawMonster(const transmatrix& V, cell *c, const transmatrix*& Vboat, transmatrix& Vboat0, ld zlev) {
|
bool drawMonster(const transmatrix& V, cell *c, const transmatrix*& Vboat, transmatrix& Vboat0, const transmatrix *Vdp) {
|
||||||
|
|
||||||
pair<mit, mit> p =
|
pair<mit, mit> p =
|
||||||
monstersAt.equal_range(c);
|
monstersAt.equal_range(c);
|
||||||
|
|
||||||
|
if(p.first == p.second) return false;
|
||||||
|
ld zlev = -geom3::factor_to_lev(zlevel(tC0((*Vdp))));
|
||||||
|
|
||||||
vector<monster*> monsters;
|
vector<monster*> monsters;
|
||||||
|
|
||||||
for(mit it = p.first; it != p.second; it++) {
|
for(mit it = p.first; it != p.second; it++) {
|
||||||
|
Loading…
Reference in New Issue
Block a user