Merge branch 'develop' into detect-manual-save

develop
Myk 2023-02-10 08:23:02 -08:00 committed by GitHub
commit c8b5f66429
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 11 additions and 8 deletions

@ -43,16 +43,17 @@ changelog.txt uses a syntax similar to RST, with a few special sequences:
-@ `automelt`: fixed bug related to lua stack smashing behavior in returned stockpile configs
-@ `autochop`: fixed bug related to lua stack smashing behavior in returned stockpile configs
- `nestboxes`: now cancels any in-progress hauling jobs when it protects a fertile egg
- Fix persisted data not being written on manual save
-@ Fix persisted data not being written on manual save
- `nestboxes`: now scans for eggs more frequently and cancels any in-progress hauling jobs when it protects a fertile egg
## Misc Improvements
- `automelt`: is now more resistent to savegame corruption
- `automelt`: is now more resistent to vanilla savegame corruption
-@ `hotkeys`: DFHack logo is now hidden on screens where it covers important information when in the default position (e.g. when choosing an embark site)
- `misery`: now persists state with the fort
- `autodump`: reinstate ``autodump-destroy-item``, hotkey: Ctrl-K
- `autodump`: new hotkey for ``autodump-destroy-here``: Ctrl-H
- `dig`: new hotkeys for vein designation on z-level (Ctrl-V) and vein designation across z-levels (Ctrl-Shift-V)
- `clean`: new hotkey for `spotclean`: Ctrl-C
-@ `clean`: new hotkey for `spotclean`: Ctrl-C
- `autobutcher`: changed defaults from 5 females / 1 male to 4 females / 2 males so a single unfortunate accident doesn't leave players without a mating pair
- `autobutcher`: now immediately loads races available at game start into the watchlist
-@ replaced DFHack logo used for the hover hotspot with a crisper image

@ -657,16 +657,18 @@ function Script:get_flags()
self.flags_mtime = mtime
self._flags = {}
local f = io.open(self.path)
local contents = f:read('*all')
f:close()
for line in contents:gmatch('^%-%-@([^\n]+)') do
local chunk = load(line, self.path, 't', self._flags)
for line in f:lines() do
local at_tag = line:match('^%-%-@(.+)')
if not at_tag then goto continue end
local chunk = load(at_tag, self.path, 't', self._flags)
if chunk then
chunk()
else
dfhack.printerr('Parse error: ' .. line)
end
::continue::
end
f:close()
end
return self._flags
end

@ -50,7 +50,7 @@ static void set_config_bool(PersistentDataItem &c, int index, bool value) {
set_config_val(c, index, value ? 1 : 0);
}
static const int32_t CYCLE_TICKS = 100; // need to react quickly if eggs are unforbidden
static const int32_t CYCLE_TICKS = 50; // need to react quickly when eggs are laid/unforbidden
static int32_t cycle_timestamp = 0; // world->frame_counter at last cycle
static void do_cycle(color_ostream &out);