Commit Graph

3121 Commits (6c6a9968ff8fa3d02ebc3c06c141497af389810a)

Author SHA1 Message Date
lethosor 06cd0c8437
Make libz.dylib optional on macOS
Thurin reports that the path specified does not exist on macOS 11.2, and DFHack links successfully without it.

CMake output from the find_package(ZLib) call in /CMakeLists.txt:
Found ZLIB: /Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.1.sdk/usr/lib/libz.tbd (found suitable version "1.2.11", minimum required is "1.1.2")
2021-02-01 23:23:19 -05:00
lethosor 353b8b71f5
Update xml 2021-01-31 13:24:21 -05:00
lethosor 233925ec75
Bump to 0.47.05-alpha0, update xml 2021-01-31 12:10:00 -05:00
lethosor 7e12f3fd3d
Fix off-by-one, adjust changelog, move scroll keys to consistent place
Ref #1748
2021-01-30 19:40:15 -05:00
lethosor 8967e98a33
Merge remote-tracking branch 'myk002/myk_scrollable_labels' into develop 2021-01-30 19:33:04 -05:00
lethosor 813a353ec2
Update xml 2021-01-30 18:08:32 -05:00
lethosor 4126585573
Merge remote-tracking branch 'lethosor/lua-runcommand' into develop 2021-01-29 20:27:38 -05:00
lethosor de6f9183fd
Fix changelog, replace a couple qerror calls with error
Ref #1746
2021-01-29 00:04:10 -05:00
lethosor d4aef78b26
Merge remote-tracking branch 'myk002/myk_getopt' into develop 2021-01-28 23:58:45 -05:00
myk002 32a0363f31
move identity check up a bit to avoid useless work 2021-01-24 08:57:56 -08:00
myk002 03719f58df
avoid infinite parentage when linking rooms 2021-01-24 08:52:34 -08:00
myk002 5a2181d55e
don't render overflow text 2021-01-13 22:02:22 -08:00
myk002 39d274b00e
address review comments 2021-01-12 23:42:53 -08:00
myk002 d4fbf4261f
address review comments 2021-01-12 23:27:14 -08:00
myk002 dac9538fd9
let navigation keys propagate
so other components can use them for simultaneous control
2021-01-11 15:02:12 -08:00
Myk Taylor 2797061b04
scroll Label text when height exceeds viewrect 2021-01-11 14:47:05 -08:00
Myk Taylor 175776812e
implement a nice API wrapper for getopt 2021-01-10 16:51:46 -08:00
Myk Taylor 3b45878d41
allow non-options in commandlines and return them
also call qerror() on error, not os.exit
2021-01-10 16:51:45 -08:00
Myk Taylor 20276be50f
check in unaltered version of alt_getopt 2021-01-10 16:51:45 -08:00
lethosor 69ce5d9e3f
Send runCommand output to correct output stream
e.g. when run with dfhack-run
2021-01-08 21:06:42 -05:00
lethosor 614ea739d0
Merge branch 'develop' into lua-runcommand 2021-01-08 20:45:23 -05:00
lethosor 462208cad3
Merge remote-tracking branch 'cvuchener/fix-loadlibrary-errormessage' into develop 2021-01-06 21:00:03 -05:00
Clément Vuchener e7748e3f73 Add an error message when LoadLibrary fails 2021-01-01 15:35:59 +01:00
lethosor b89fe222c7
Update xml 2020-12-29 23:47:44 -05:00
lethosor eb6957a167
Bump to 0.47.04-r4 and update submodules 2020-12-24 13:32:44 -05:00
myk002 3ba984c22c
only reset extents if they are unusable
this allows callers of Buildings::setSize() to "pre-initialize" the
extents to declare non-rectangular structures. this allows quickfort to
create non-rectangular stockpiles, farm plots, zones, etc. the extents
are still reset as before if the size of the building doesn't match the
caller's expectations.

this commit also fixes a memory leak when setSize() allocates memory for
extents, but the memory is not deallocated if the building is ultimately
invalid for some reason.
2020-12-16 11:10:47 -08:00
lethosor 159695775e
Merge branch 'develop' into lua-runcommand 2020-12-05 19:49:55 -05:00
lethosor 855ce84eca
Update submodules 2020-12-04 23:55:43 -05:00
lethosor af2255956a
Update submodules 2020-12-03 23:00:21 -05:00
lethosor fe0cd9a939
Make lineedit() fail sooner when another lineedit() call is active
Before, calling `dfhack.run_command('tiletypes')` from a `dfhack.timeout` callback would leave the console in a broken state, since raw mode was enabled but never disabled.

Only tested on Linux with a supported terminal.
2020-12-03 22:04:00 -05:00
lethosor a9bb11c145
Optimize Lua's internal.runCommand() when printing directly to the console
This also makes commands run with `run_command()` detect the console properly (notably used by `df2console()`)
2020-11-20 17:57:54 -05:00
lethosor fb44b26b47
Make utils.addressof() work for raw userdata 2020-11-19 21:32:42 -05:00
lethosor 8cb38ecf5b
Merge remote-tracking branch 'myk002/myk_metalhead_mario' into develop 2020-11-13 14:04:30 -05:00
myk002 76e8c495fe
revert skip_vector=true for now 2020-11-13 10:45:53 -08:00
myk002 fa126af1fd
undo unnecessary edits 2020-11-12 22:49:06 -08:00
myk002 10616a387f
cleaner mask-based implementation 2020-11-12 22:44:38 -08:00
myk002 02a86d761a
identify bars as non_economic items
allows Job::isSuitableMaterial() to match metal bars as a building
material
2020-11-12 19:10:06 -08:00
lethosor 913d860ae4
Use initial working directory as process path on Linux, and expose to Lua 2020-11-12 19:07:51 -05:00
lethosor 23b230495e
Merge branch 'develop' into cwd-handling 2020-11-12 18:44:05 -05:00
lethosor 421844dcb8
Update xml 2020-11-11 16:05:24 -05:00
lethosor eee33822e7
Update submodules 2020-11-09 23:41:53 -05:00
lethosor 3aa902bd25
Update submodules 2020-11-03 19:52:24 -05:00
lethosor 1d0e2dc6bc
Update extents handling to use building_extents_type 2020-11-03 14:56:16 -05:00
lethosor 3b4d6de454
Merge remote-tracking branch 'myk002/quickfort_building_types' into develop 2020-10-27 23:14:38 -04:00
Myk Taylor 186f28a94b filters for altars, display cases, and bookcases 2020-10-23 09:11:07 -07:00
Myk Taylor 09fbaba726 buildingplan: support all building types
Allow buildingplan to handle all building types, update the docs, and add in little extra fixes to ensure all the new types work correctly.
2020-10-16 14:23:35 -07:00
Myk Taylor 82013c0c5e prep buildingplan for core algorithm changes
Lots of refactoring and reorganizing, with only cosmetic player-visible changes.

- show quickfort mode hotlkey label regardless of whether the current building type has buildingplan enabled. before, it was only shown after the user enabled buildingplan for the current building. this eliminates the extra step when enabling quickfort mode, which force-enables all building types.
- changed signature of lua-exported isPlannableBuilding to take subtype
  and custom type in addition to building type. this is only used by
  quickfort, and it already sends all three params in preparation for
  this change
- added lua-exported scheduleCycle(), which is like doCycle(), but only
  takes effect on the next non-paused frame. this lets quickfort
  run only one buildingplan cycle regardless of how many #build
  blueprints were run
- declared a few dfhack library methods and params const so buildingplan
  could call them from const methods
- converted buildingplan internal debug logging fn to have a printf api
- reshaped buildingplan-planner API and refactored implementation in
  preparation for upcoming core algorithm changes for supporing all
  building types (no externally-visible functionality changes)
  - changed df::building_type params to type, subtype, custom tuple keys
  - introduced capability to return multiple filters per building type
    (though the current buildings all only have one filter per)
- split monolith hook functions in buildingplan.cpp into one per scope.
  this significantly cleans up the code and preps the hooks to handle
  iterating through multiple item filters.
- got rid of send_key function and replaced with better reporting of
  whether keys have been handled
2020-10-16 13:52:23 -07:00
lethosor ce7772a1c2
Add Filesystem::restorecwd()
This allows restoring the working directory to its original value, which may not actually be the DF root. See #1671, dfhack/scripts#152
2020-10-14 21:22:53 -04:00
lethosor b343d00800
Update to 0.47.04-r3 (authors, changelog, and submodules) 2020-10-10 17:31:30 -04:00
lethosor 9c8098b4f0
Expose to_search_normalized to Lua, add test, and use in ListColumn (most useful for the `stocks` plugin) 2020-10-10 01:40:00 -04:00