From 8794c78ad9ba05a9ee4e7c89bf2a8f75e03429f9 Mon Sep 17 00:00:00 2001 From: Jesse Ruderman Date: Thu, 1 Jul 2021 01:24:39 -0700 Subject: [PATCH] Orb of Safety excludes more monsters --- landgen.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/landgen.cpp b/landgen.cpp index 11b03625..d1e77197 100644 --- a/landgen.cpp +++ b/landgen.cpp @@ -2192,11 +2192,11 @@ EX void giantLandSwitch(cell *c, int d, cell *from) { case laMountain: if(d == 7) { - if(hrand_monster(50000) < 100) + if(hrand_monster(50000) < 100 && !safety) buildIvy(c, 0, 3); - else if(hrand_monster(125000) < 100 - celldistAlt(c)) + else if(hrand_monster(125000) < 100 - celldistAlt(c) && !safety) c->monst = moMonkey; - else if(hrand_monster(200000) < min(100, -10*celldistAlt(c)) - celldistAlt(c)) + else if(hrand_monster(200000) < min(100, -10*celldistAlt(c)) - celldistAlt(c) && !safety) c->monst = moEagle; else if(hrand(100) < 5) c->wall = waPlatform; @@ -2333,7 +2333,7 @@ EX void giantLandSwitch(cell *c, int d, cell *from) { c->wall = waRuinWall, c->landparam = 1; } } - if(hrand_monster(40000) < kf && !c->monst && !c->wall && !shmup::on) { + if(hrand_monster(40000) < kf && !c->monst && !c->wall && !shmup::on && !safety) { cell *c1 = c; cell *c2 = createMov(c1, hrand(c1->type)); if(c2->monst || c2->wall) return; @@ -2758,7 +2758,7 @@ EX void giantLandSwitch(cell *c, int d, cell *from) { } } - if(d == 7) { + if(d == 7 && !safety) { if(c->wall == waNone) { if(hrand_monster(2000) < ((cwt.at->land == laFrog || items[itFrog]) ? 20 : 0) + (items[itFrog] + yendor::hardness())) c->monst = pick(moFrog, moPhaser, moVaulter);