1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2025-08-27 16:02:19 +00:00

Merge pull request #434 from josephcsible/push-unhappy-die-message

Fix pushing an Animated Die saying "You push the Unhappy Die."
This commit is contained in:
Zeno Rogue 2025-08-25 21:16:53 +02:00 committed by GitHub
commit 50960a0761
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -754,6 +754,7 @@ void apply_chaos() {
}
bool pcmove::actual_move() {
eMonster pushedMonster = moNone;
origd = d;
if(d >= 0) {
@ -805,6 +806,7 @@ bool pcmove::actual_move() {
if(mip.proper()) {
auto tgt = roll_effect(mip, dice::data[c2]);
if(tgt.happy() > 0) {
pushedMonster = c2->monst;
changes.ccell(c2);
c2->monst = moNone;
c2->wall = waRichDie;
@ -840,7 +842,8 @@ bool pcmove::actual_move() {
return false;
}
nextmovetype = lmMove;
addMessage(XLAT("You push %the1.", c2->wall));
if(pushedMonster == moNone) addMessage(XLAT("You push %the1.", c2->wall));
else addMessage(XLAT("You push %the1.", pushedMonster));
lastmovetype = lmPush; lastmove = cwt.at;
pushThumper(mip);
changes.push_push(mip.t);