mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-12-24 17:10:36 +00:00
some extra commandline options
This commit is contained in:
parent
c3d38e2e1c
commit
a6563420ed
@ -127,6 +127,18 @@ int arg::readCommon() {
|
|||||||
shift(); int q = argi();
|
shift(); int q = argi();
|
||||||
placeItems(q, i);
|
placeItems(q, i);
|
||||||
}
|
}
|
||||||
|
else if(argis("-IU")) {
|
||||||
|
PHASE(3) cheater++; timerghost = false;
|
||||||
|
shift(); eItem i = readItem(args());
|
||||||
|
shift(); inv::usedup[i] += argi();
|
||||||
|
inv::compute();
|
||||||
|
}
|
||||||
|
else if(argis("-IX")) {
|
||||||
|
PHASE(3) autocheat = true; cheater++; timerghost = false;
|
||||||
|
shift(); eItem i = readItem(args());
|
||||||
|
shift(); inv::extra_orbs[i] += argi();
|
||||||
|
inv::compute();
|
||||||
|
}
|
||||||
else if(argis("-ambush")) {
|
else if(argis("-ambush")) {
|
||||||
// make all ambushes use the given number of dogs
|
// make all ambushes use the given number of dogs
|
||||||
// example: hyper -W Hunt -IP Shield 1 -ambush 60
|
// example: hyper -W Hunt -IP Shield 1 -ambush 60
|
||||||
@ -140,6 +152,11 @@ int arg::readCommon() {
|
|||||||
printf("m = %s q = %d\n", dnameof(m), q);
|
printf("m = %s q = %d\n", dnameof(m), q);
|
||||||
restoreGolems(q, m, 7);
|
restoreGolems(q, m, 7);
|
||||||
}
|
}
|
||||||
|
else if(argis("-MK")) {
|
||||||
|
PHASE(3) cheater++; timerghost = false;
|
||||||
|
shift(); eMonster m = readMonster(args());
|
||||||
|
shift(); kills[m] += argi();
|
||||||
|
}
|
||||||
else if(argis("-L")) {
|
else if(argis("-L")) {
|
||||||
printf("Treasures:\n");
|
printf("Treasures:\n");
|
||||||
for(int i=1; i<ittypes; i++)
|
for(int i=1; i<ittypes; i++)
|
||||||
|
@ -1,8 +1,9 @@
|
|||||||
namespace inv {
|
namespace inv {
|
||||||
|
|
||||||
bool on;
|
bool on;
|
||||||
int usedup[ittypes];
|
array<int, ittypes> usedup;
|
||||||
int remaining[ittypes];
|
array<int, ittypes> remaining;
|
||||||
|
array<int, ittypes> extra_orbs;
|
||||||
|
|
||||||
int rseed;
|
int rseed;
|
||||||
bool usedForbidden;
|
bool usedForbidden;
|
||||||
@ -254,7 +255,7 @@ namespace inv {
|
|||||||
extra = "";
|
extra = "";
|
||||||
orbinfoline = "";
|
orbinfoline = "";
|
||||||
|
|
||||||
for(int i=0; i<ittypes; i++) remaining[i] = -usedup[i];
|
for(int i=0; i<ittypes; i++) remaining[i] = extra_orbs[i]-usedup[i];
|
||||||
for(int i=0; i<ittypes; i++) if(usedup[i] >= TESTMIRRORED) {
|
for(int i=0; i<ittypes; i++) if(usedup[i] >= TESTMIRRORED) {
|
||||||
remaining[i] += MIRRORED;
|
remaining[i] += MIRRORED;
|
||||||
remaining[i] -= mirrorqty0(eItem(i));
|
remaining[i] -= mirrorqty0(eItem(i));
|
||||||
@ -360,7 +361,6 @@ namespace inv {
|
|||||||
for(int i=0; i<ittypes; i++)
|
for(int i=0; i<ittypes; i++)
|
||||||
if(i != itGreenStone && i != itOrbYendor)
|
if(i != itGreenStone && i != itOrbYendor)
|
||||||
items[itInventory] += remaining[i];
|
items[itInventory] += remaining[i];
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
map<char, eItem> orbmap;
|
map<char, eItem> orbmap;
|
||||||
|
Loading…
Reference in New Issue
Block a user