mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-01-22 23:17:04 +00:00
first approach to Cursed Land
This commit is contained in:
parent
6277ba6143
commit
809d1510c2
@ -1681,6 +1681,11 @@ ITEM('>', 0xFF6060, "fatigue", itFatigue, IC_NAI, ZERO, RESERVED, osNone,
|
||||
MONSTER('H', 0x181818, "Hag", moHexer, CF_FACE_UP, RESERVED, moYeti,
|
||||
"Hags can curse you from afar!")
|
||||
|
||||
LAND(0xC0C0FF, "Cursed Land", laCursed, 0, itCursed, RESERVED,
|
||||
"This land is full of curses!")
|
||||
|
||||
ITEM('/', 0x211F6F, "Cursed Gold", itCursed, IC_TREASURE, ZERO, RESERVED, osNone,
|
||||
"A cursed gold.")
|
||||
|
||||
//shmupspecials
|
||||
MONSTER( '@', 0xC0C0C0, "Rogue", moPlayer, CF_FACE_UP | CF_PLAYER, RESERVED, moNone, "In the Shoot'em Up mode, you are armed with thrown Knives.")
|
||||
|
35
landgen.cpp
35
landgen.cpp
@ -2584,7 +2584,40 @@ EX void giantLandSwitch(cell *c, int d, cell *from) {
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
case laCursed: {
|
||||
if(fargen) {
|
||||
c->wall = waStone;
|
||||
for(int i=0; i<3; i++) {
|
||||
auto ew = [i] (cell *c1) {
|
||||
return getCdata(c1, i) & 64;
|
||||
};
|
||||
int val = ew(c);
|
||||
forCellCM(c1, c) if(ew(c1) != val)
|
||||
c->wall = waNone;
|
||||
}
|
||||
}
|
||||
if(d == 7) {
|
||||
if(c->wall == waNone) {
|
||||
int wals = 0;
|
||||
forCellCM(c1, c) if(c1->wall == waStone || c1->wall == waRubble || c1->land != laCursed)
|
||||
wals++;
|
||||
if(!wals) c->wall = waDeepWater;
|
||||
}
|
||||
if(c->wall == waStone && hrand(100) < 20)
|
||||
c->wall = waRubble;
|
||||
}
|
||||
ONEMPTY {
|
||||
if(hrand(5000) < 30 + kills[moHexer] && notDippingFor(itCursed))
|
||||
c->item = itCursed;
|
||||
else if(hrand(5000) < 30)
|
||||
c->item = pick(itCurseWeakness, itCurseDraining, itCurseWater, itCurseFatigue, itCurseRepulsion, itCurseGluttony);
|
||||
if(hrand_monster(4000) < 10 + items[itCursed] + yendor::hardness() && !safety)
|
||||
c->monst = moHexer;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
case laNone:
|
||||
case laBarrier:
|
||||
case laOceanWall:
|
||||
|
@ -1449,7 +1449,7 @@ EX void moveshadow() {
|
||||
cshpos = (cshpos+1) % SHSIZE;
|
||||
for(int p: player_indices()) {
|
||||
cell* where = shpos[p][cshpos];
|
||||
if(where && where->monst == moNone && where->cpdist && where->land == laGraveyard &&
|
||||
if(where && where->monst == moNone && where->cpdist && among(where->land, laGraveyard, laCursed) &&
|
||||
!sword::at(where)) {
|
||||
if(shfrom) animateMovement(match(shfrom, where), LAYER_SMALL);
|
||||
where->monst = moShadow;
|
||||
|
Loading…
Reference in New Issue
Block a user