1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-12-24 17:10:36 +00:00

arb:: set sliders from command line

This commit is contained in:
Zeno Rogue 2020-06-03 11:44:00 +02:00
parent e3664c79a3
commit efe4e20cd4

View File

@ -885,6 +885,21 @@ int readArgs() {
shift();
run(args());
}
else if(argis("-arb-slider")) {
PHASEFROM(2);
shift();
string slider = args();
bool found = true;
for(auto& sl: current.sliders)
if(sl.name == slider) {
shift_arg_formula(sl.current, sliders_changed);
found = true;
}
if(!found) {
println(hlog, "warning: no slider named ", slider, " found");
shift();
}
}
else return 1;
return 0;
}