error out on missing burrow specification

develop
Myk Taylor 2023-12-31 01:17:54 -08:00
parent 02c692150b
commit 3c54ba7c09
No known key found for this signature in database
1 changed files with 5 additions and 1 deletions

@ -32,7 +32,11 @@ function setTargets(max, min)
end
local function do_set_burrow_config(var_name, val, burrows)
for _,bspec in ipairs(argparse.stringList(burrows)) do
burrows = argparse.stringList(burrows)
if #burrows == 0 then
qerror('no target burrows specified')
end
for _,bspec in ipairs(burrows) do
local config = autochop_getBurrowConfig(bspec)
config[var_name] = val
autochop_setBurrowConfig(config.id, config.chop, config.clearcut,