1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2025-09-06 12:27:57 +00:00

Strong Wind and Orb of Vaulting now better with Orb of the Sword

This commit is contained in:
Zeno Rogue
2024-10-11 17:09:37 +02:00
parent d90dcdcff5
commit 568389e629
5 changed files with 69 additions and 34 deletions

View File

@@ -162,15 +162,19 @@ EX namespace whirlwind {
}
}
EX cell *jumpFromWhereTo(cell *c, bool player) {
EX cell *jumpFromWhereTo(cell *c, bool player, struct jumpdata& jdata) {
jdata.uniq = true;
for(int i=0; i<2; i++) {
calcdirs(c);
if(qdirs != 1) return NULL;
auto mi = movei(c, dfrom[0]);
jdata.moves.push_back(mi.rev());
cell *c2 = c->move(dfrom[0]);
if(!passable(c, c2, P_JUMP1)) return NULL;
if(player && i == 0 && !passable(c, c2, P_ISPLAYER)) return NULL;
c = c2;
}
reverse(jdata.moves.begin(), jdata.moves.end());
calcdirs(c);
if(qdirs != 1) return NULL;
return c;