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:
parent
e3664c79a3
commit
efe4e20cd4
@ -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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user