1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-11-07 22:49:54 +00:00

bow:: fixed mirrors in fire mode

This commit is contained in:
Zeno Rogue 2024-01-11 17:01:46 +01:00
parent 8ce805372d
commit bdd2b5e9fd

View File

@ -340,13 +340,18 @@ bool pcmove::movepcto() {
changes.init(checkonly);
changes.value_keep(bow::bowpath_map);
bow::bowpath_map.clear();
bool b = (d >= 0 && bow::fire_mode) ? (origd = d, cwt += d, false) : (d >= 0) ? actual_move() : stay();
bool b = (d >= 0 && bow::fire_mode) ? false : (d >= 0) ? actual_move() : stay();
if(checkonly || !b) {
changes.rollback();
if(!checkonly) flipplayer = false;
if(!b && items[itCrossbow] == 0 && bow::crossbow_mode() && bow::bump_to_shoot && d >= 0 && !checkonly) {
changes.init(checkonly);
if(bow::fire_mode) {
origd = d;
cwt += d;
mirror::act(d, mirror::SPINSINGLE);
}
changes.value_keep(bow::bowpath_map);
b = try_shooting(true);
if(checkonly || !b) changes.rollback();