RemoteServer and PluginManager side would need complete redesign to be
data race free and concurrent. But as that would be unlikely to be
required from DFHack I decided simpler solution that is fixing data
ownership to a thread and all ServerConnection share a single lock which
allows access to PluginManager and Core.
The initial run_dfhack_init loads shared state information that is used
by EventManager when state changes. There is a small risk that
EventManager can handle events while run_dfhack_init is still running.
Fixes tsan trace report between lua viewscreen and other threads running
lua without CoreSuspender lock. But I would assume similar races exists
when using lua from console thread, remote thread and vmethods same time.
githubbadges.herokuapp.com has been down for some time, and these badges
repeated information that was already visible on
https://github.com/dfhack/dfhack (and they weren't included in the generated
docs either).
Have been messing with this function in the dfhack repl and when it returns nil it's hard to know what that means unless you have also already read the code. So this handles a couple spots in `unit_ishostile` that previously just returned false-ey `nil`s to return `false`
TWBT modifies the map dimensions, so using the window dimensions to handle edge
scrolling produces the wrong behavior when using a larger map tileset than text
tileset.
This partially reverts f02466de8a, but behavior
should be the same under MSVC, which that commit attempted to fix. From
https://cmake.org/cmake/help/v3.14/command/add_custom_command.html:
> The `BYPRODUCTS` option is ignored on non-Ninja generators except to mark
> byproducts `GENERATED`.
Since `$GENERATED_HDRS` are already marked generated, this change should have
no effect on non-Ninja generators.