mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2026-03-25 05:59:43 +00:00
redone hrmap::draw() function to keep DRY
This commit is contained in:
@@ -417,26 +417,6 @@ EX namespace bt {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void draw() override {
|
||||
dq::clear_all();
|
||||
dq::enqueue(centerover->master, cview());
|
||||
|
||||
while(!dq::drawqueue.empty()) {
|
||||
auto& p = dq::drawqueue.front();
|
||||
heptagon *h = p.first;
|
||||
shiftmatrix V = p.second;
|
||||
dq::drawqueue.pop();
|
||||
|
||||
|
||||
cell *c = h->c7;
|
||||
if(!do_draw(c, V)) continue;
|
||||
drawcell(c, V);
|
||||
|
||||
for(int i=0; i<h->type; i++)
|
||||
dq::enqueue(h->cmove(i), optimized_shift(V * adj(h, i)));
|
||||
}
|
||||
}
|
||||
|
||||
int updir_at(heptagon *h) {
|
||||
if(geometry != gBinaryTiling) return updir();
|
||||
else if(type_of(h) == 6) return bd_down;
|
||||
|
||||
Reference in New Issue
Block a user