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

added a hook on cellgen

This commit is contained in:
Zeno Rogue 2020-08-23 00:16:32 +02:00
parent 01ed0290c2
commit fe2d9e7da8

View File

@ -2764,6 +2764,8 @@ EX void set_land_for_geometry(cell *c) {
else if(weirdhyperbolic) setLandWeird(c);
}
EX hookset<bool(cell *c, int d, cell *from)> hooks_cellgen;
EX void setdist(cell *c, int d, cell *from) {
if(fake::in()) return FPIU(setdist(c, d, from));
@ -2957,6 +2959,8 @@ EX void setdist(cell *c, int d, cell *from) {
#endif
}
callhandlers(false, hooks_cellgen, c, d, from);
if(PURE && c->wall == waMirrorWall && c->land == laMirror)
c->land = laMirrorWall; // , c->item = itPirate; // not really a proper bugfix