mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-12-30 12:00:35 +00:00
newlands:: fixed Orb of Choice
This commit is contained in:
parent
acdb9d2219
commit
30c4d798db
6
game.cpp
6
game.cpp
@ -6887,6 +6887,7 @@ bool collectItem(cell *c2, bool telekinesis) {
|
|||||||
|
|
||||||
int pg = gold();
|
int pg = gold();
|
||||||
bool dopickup = true;
|
bool dopickup = true;
|
||||||
|
bool had_choice = false;
|
||||||
|
|
||||||
if(cannotPickupItem(c2, telekinesis))
|
if(cannotPickupItem(c2, telekinesis))
|
||||||
return false;
|
return false;
|
||||||
@ -6928,6 +6929,7 @@ bool collectItem(cell *c2, bool telekinesis) {
|
|||||||
else if(it == itOrbSpeed) playSound(c2, "pickup-speed");
|
else if(it == itOrbSpeed) playSound(c2, "pickup-speed");
|
||||||
else if(it == itRevolver) playSound(c2, "pickup-key");
|
else if(it == itRevolver) playSound(c2, "pickup-key");
|
||||||
else playSound(c2, "pickup-orb");
|
else playSound(c2, "pickup-orb");
|
||||||
|
if(items[itOrbChoice]) items[itOrbChoice] = 0, had_choice = true;
|
||||||
int oc = orbcharges(it);
|
int oc = orbcharges(it);
|
||||||
if(markOrb(itOrbBrown)) oc = oc * 6 / 5;
|
if(markOrb(itOrbBrown)) oc = oc * 6 / 5;
|
||||||
if(!items[it]) items[it]++;
|
if(!items[it]) items[it]++;
|
||||||
@ -7098,9 +7100,7 @@ bool collectItem(cell *c2, bool telekinesis) {
|
|||||||
c2->landparam &= ~1;
|
c2->landparam &= ~1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(items[itOrbChoice] && itemclass(c2->item) == IC_ORB)
|
if(!had_choice)
|
||||||
items[itOrbChoice] = 0;
|
|
||||||
else
|
|
||||||
c2->item = itNone;
|
c2->item = itNone;
|
||||||
}
|
}
|
||||||
// if(c2->land == laHive)
|
// if(c2->land == laHive)
|
||||||
|
Loading…
Reference in New Issue
Block a user