Commit Graph

576 Commits (5b9c18fc3cabc8d8cdeb1a28154d073e3ae6c458)

Author SHA1 Message Date
Josh Cooper fe29bff845
Adds cxxrandom unit test and fixes interface problems (#2099)
* Adds cxxrandom unit test and fixes interface problems

* Tightens braces

* Adds detection code for Shuffle's seqID/engID

* Adds usage examples for cxxrandom

* Gives cxxrandom objects id ranges, sort of

* Updates changelog

* Updates changelog.txt

* Increases id space for cxxrandom

* Fixes bool distribution error message and improves check

* Adds comment explaining the seeded RNG tests for cxxrandom

* Fixes type problem for 32bit builds

* Reduces loop count a few magnitudes

* Fixes a mistake in test.cxxrandom_seed
2022-04-30 21:46:47 -07:00
Myk e2fb15a3a5
add dwarfmode.MenuOverlay:renderMapOverlay() (#2119)
* add dwarfmode.MenuOverlay:renderMapOverlay()

* ensure we move with the viewport when bounds_rect is nil
2022-04-29 20:32:22 -07:00
Myk 24dd4d8ac0
Update init files (#2117)
* update example init files

replace onLoad.init-example with documentation on how to create scripts that run on world/map load
it was confusing to show it being loaded with sc-script since it gets autorun anyway if it is just named properly

* update changelog

* add quickfort keybinding

* move standard tweaks from dreamfort init to main
2022-04-29 20:24:09 -07:00
Tachytaenius b9c36c1e63
Added custom-raw-tokens utility (#2038)
* Added (chain) for [CHAIN_METAL_TEXT] armours in gui/materials.lua used by gui/create-item-- again (oops)

* Added customRawData utility

* Oops, whitespace

* Revised rawStringsFieldNames

* Dialed down on lua trickery and fixed wrongly formatted changelog entry

* Fixed changelog in wrong place and made customRawData a proper module

* Fixed not caching not-present tags, revised examples and fixed error

* Fixed whitespace. Changing settings in editor!

* customRawData docs

* Added getCreatureTag for respecting caste tags, "fixed" bizarre caching error (quotes because I don't even know what was causing it) and updated docs

* Added line limiting for docs, I guess

* Added missing string convert argument

* docs indent fix, code block fix, and revision

* Major revision

* gdi, docs error

* Another? But... huh.

* ...

* Made requested changes

* Whoops

* Rearrange docs lines

* Followed example, should fix linter issues

* fix typo. linted offline this time......

* Make it so that last instance of tag is what is read from

* Added requested change

* eventful key change

* i to lenArgs

* change eventful key

* add test for broken caste selection

* Major redesign

* tags --> tokens

* Added plant growth behaviour and did some requested changes

* More error handling

* fix docs

* Added basic error suppression

* Docs clarification.

* Docs registering example and fix error

* Strip errors on frame after onWorldLoad, not on map load

* Revert "Strip errors on frame after onWorldLoad, not on map load"

This reverts commit e20a0ef8d3743f79d961077f46910b77b16f36b9.

* Revert "Docs registering example and fix error"

This reverts commit 9c848c54c3f84e0ecc1dc421137c8a8b4a52280d.

* Revert "Docs clarification."

This reverts commit 6b4b6a1aa40c50398504f37ecf1ff0f93d6459b1.

* Revert "Added basic error suppression"

This reverts commit d11cb1438cf1e56ff700469e944f0b9af64651d7.

* Use more eventful key more consistent with other files

* use onStateChange instead of eventful and remove redundant utils require

* Code review stuff

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update docs/Lua API.rst

committing a suggestion

Co-authored-by: Alan <lethosor@users.noreply.github.com>

* Prepend examples with DFHACK_

* Remove unused parameters

* Use new ensure_key global

* Named a couple of unnamed arguments (untested)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Alan <lethosor@users.noreply.github.com>
2022-04-29 08:39:59 -07:00
myk002 dcadde38d7 add new global function: ensure_key 2022-04-27 17:35:49 -07:00
myk002 6ad362d698
return a reference to the created dialogs 2022-04-27 11:51:46 -07:00
Quietust dc2a14c0c2 Add "partial-items" tweak.
When active, the displayed names of partially-consumed items (e.g.
hospital cloth) will display a percentage indicator at the end.

Also re-sort a few Tweaks so they're in alphabetical order again.
2022-04-27 11:27:11 -07:00
myk002 ed5523152c
factor text wrapping out of TooltipLabel into WrappedLabel 2022-04-22 09:53:10 -07:00
Guilherme Abraham 2aa28d34b6
Adding ids output to cursecheck (#2093)
Co-authored-by: Guilherme Abraham <guilherme.abraham@zpesystems.com>
Co-authored-by: Myk <myk002@yahoo.com>
2022-04-21 20:22:05 -07:00
myk002 07761e1d5d add some more handy widgets to the library
TooltipLabel
HotkeyLabel
CycleHotkeyLabel
ToggleHotkeyLabel
2022-04-18 17:37:11 -07:00
Timur Kelman cb123e5076
default unset `frame_inset` values to 0 (#2100)
* default unset `frame_inset` values to 0

This change allows writing `frame_inset = {r=1}` instead of `frame_inset = {l=0, r=1, t=0, b=0}`
2022-04-16 08:17:35 -07:00
Tim Siegel bf60879c81 [tweak/stable-cursor] Keep stable cursor when viewport is near enough
Allow the viewport to move a bit and still keep the cursor location.
2022-04-12 19:53:16 -07:00
Myk fd1ee233a2
automatically manage sidebar modes in MenuOverlay (#2083) 2022-04-11 20:58:54 -07:00
Myk 10f22ecc27
add ResizingPanel class and autolayout for Panels (#2086)
* add autolayout for Panels and new ResizingPanel
2022-04-11 18:25:00 -07:00
Myk e6299700bf
Handle punctuation in FilteredList filter matching (#2085)
* allow punctuation to be typed into a filter

and allow the filter to match keys with punctuation
2022-04-11 18:22:31 -07:00
myk002 4a383b1c84 handle number-indexed lua maps in safe_index 2022-04-11 18:02:57 -07:00
Myk 9a8fd12785
ensure ListBoxes always have enough height (#2084)
so they can always display an error message if the filter doesn't match anything
2022-04-11 16:15:50 -07:00
Myk 96b5b4420b
Add string:escape_pattern() utility function (#2082)
* add string:escape_pattern() to dfhack.lua

stolen from devel/query.lua. will migrate scripts to use the common implementation later
2022-04-10 21:18:01 -07:00
myk002 54e8761aa0 capture fortifications and engravings in blueprint 2022-04-01 12:20:37 -07:00
Su 8a120837c6
only designate enough trees to reach max_logs (#2064)
* only designate enough trees to reach max_logs
* Chop largest trees first
2022-03-31 20:41:44 -07:00
Tim Siegel b5af004194
[manipulator] Tweak colors to make cursor easier to locate (#2051) 2022-03-30 23:39:20 -07:00
myk002 e286b2a54d
update changelog 2022-03-30 14:42:37 -07:00
myk002 db5e7d55c1 fix guidm.enterSidebarMode(DesignateMine)
it would end up in DesignateChopTrees if you happened to be looking at
the surface z-level.
2022-03-28 16:57:24 -07:00
myk002 078e732a42 update changelog 2022-03-28 16:00:29 -07:00
Tim Siegel ab54cbff7a
[confirm] Fix typo in help message (#2046) 2022-03-23 19:45:13 -07:00
Tachytaenius 19c0a4fe06
Added (chain) for [CHAIN_METAL_TEXT] armours in library/gui/materials.lua used by the gui/create-item script (#2037) 2022-03-19 15:32:16 -07:00
Kelly Kinkade e1961f5fcd
visual studio 2022/2019 build instructions (#2034)
* visual studio 2022/2019

update instructions to recommend using VS 2022 or VS 2019 with downlevel tool support

* reinsert accidentally deleted line

* fix markup

* notes on abi compatibility, changelog
2022-03-17 13:19:12 -07:00
Zishi Wu ce30843b92
update Windows build docs for Visual C++ 2015 (#2032)
* update Windows build docs for Visual C++ 2015

* fixed doc errors / moved changelog entry to future section
2022-03-16 13:10:00 -07:00
Kelly Kinkade 07e96a6a1c Update changelog.txt 2022-03-15 08:23:18 -07:00
Josh Cooper dda487a535
Adds new plugin: Spectate (#1918)
* Adds spectate plugin

* Updates spectate.cpp

* Changes spectate toggle message

* Updates changelog.txt

* Adds spectate to Plugins.rst

* Adds requested changes

- foreach syntax replaces active units loops
- removes CR_FAILURE return on double enable/disable usage
- removes disabled code
- implements a few clion clang tidy suggestions (auto declare when casting)
- Updates zcount to have accurate count for performing RNG
- adds eof newline
- adds todo comment about a redundant if condition

* Declares spectate section in Plugins.rst
2022-03-14 19:33:41 -07:00
Ryan Williams 88b403ec7a
Add functions reverse-engineered from ambushing unit code (#1992)
* Add functions reverse-engineered from ambushing unit code

* Fix whitespace

* Fix debug_showambush check

* Remove getOuterContainerRef from Lua API

Don't think this works properly without allocating a new specific_ref. More trouble that it's worth.

* Fixed tile visibility check

* I don't think gamemode or gametype are ever NULL

* Minor tweaks to documentation

* Reimplement getOuterContainerRef for Lua; fix some comments

* Update Units.cpp and changelog

* Update Units.cpp
* Update changelog.txt
2022-03-13 17:19:35 -07:00
Kelly Kinkade d2d01843a2 Update changelog.txt
update changelog for changes to Job::remove_postings
2022-03-12 15:37:33 -08:00
myk002 89a3ca8ee9 update docs and changelog 2022-03-12 13:45:32 -08:00
myk002 25d37143e4 update changelog 2022-03-12 13:33:36 -08:00
myk002 82910015c1 update changelog 2022-03-12 12:41:19 -08:00
myk002 9f8a477f09
move EventManager changelog entries to 'Future'
ref: #1876
2022-03-12 11:38:43 -08:00
Josh Cooper 28ebc3921d Revises changelog 2022-03-12 11:33:27 -08:00
Josh Cooper 0cb6e18e16 Adds changelog entries for PR #1876 2022-03-12 11:33:27 -08:00
myk002 2c3f573610
really fix the docs typo 2022-03-10 20:03:37 -08:00
myk002 a1e3f2dbe1
fix typo in docs 2022-03-10 18:31:16 -08:00
myk002 858d459232
update changelog for clsocket PR#20 2022-03-10 14:07:48 -08:00
myk002 cf54b84fd6 Bump to 0.47.05-r4 2022-03-09 14:27:20 -08:00
myk002 7aaccb781e update changelog 2022-03-03 21:37:38 -08:00
myk002 c752fa07a8 update changelog 2022-03-01 05:44:36 -08:00
myk002 4d47bf54ce update changelog 2022-02-26 15:32:25 -08:00
myk002 41ea2527eb update changelog 2022-02-26 14:54:42 -08:00
myk002 0362c09811 update changelog 2022-02-25 12:59:38 -08:00
myk002 5937e55cfd update changelog 2022-02-25 12:58:56 -08:00
myk002 1d6b942293 update wording in changelog 2022-02-25 12:57:17 -08:00
myk002 e458e74058 use correct header in changelog 2022-02-25 12:57:17 -08:00
myk002 6b0f2eace9 update changelog 2022-02-25 12:57:17 -08:00
myk002 91b55a648b update changelog 2022-02-19 17:54:01 -08:00
myk002 3dcc6fd899 update changelog 2022-02-18 15:47:33 -08:00
myk002 5d6f88fa72 update changelog 2021-10-04 15:32:26 -07:00
myk002 86cd723162 update changelog 2021-10-04 12:53:31 -07:00
myk002 8245db8862 update changelog 2021-10-03 08:54:27 -07:00
myk002 438f030221 update changelog 2021-10-02 23:36:26 -07:00
myk002 d013b336ba update changelog 2021-10-02 12:50:47 -07:00
myk002 06916280f4 update changelog 2021-10-02 09:26:32 -07:00
myk002 850da0b5e4 move changelog entries to correct version 2021-10-02 09:25:19 -07:00
myk002 e3f723c6a2 update changelog 2021-10-02 09:25:19 -07:00
myk002 3c91f55612 update changelog 2021-09-25 22:00:49 -07:00
myk002 50a16ac147 update changelog 2021-09-22 10:30:41 -07:00
myk002 e328609ac4 update changelog 2021-09-20 16:10:15 -07:00
myk002 0410aaeaf0 update changelog 2021-09-10 11:11:44 -07:00
myk002 3d1e3f0832 update changelog 2021-09-09 09:58:53 -07:00
myk002 9cdf3d9605 update changelog 2021-09-09 09:58:23 -07:00
myk002 8c0fccb406 update changlog 2021-09-09 00:35:15 -07:00
lethosor a083a7f670
tailor: fix operator precedence in command parsing
&& has a higher precendence than ||, so this could have resulted in a crash in
some cases. It also produced unintentional behavior where e.g. `tailor 1 foo`
would enable the plugin, unlike `tailor enable foo`.

From #1920
2021-09-06 22:35:38 -04:00
lethosor 1295633722
Bump to 0.47.05-r3 2021-09-04 14:00:31 -04:00
lethosor 0d14a2ccef
Merge remote-tracking branch 'ab9rf/tailor-v2' into develop
Conflicts: docs/changelog.txt
2021-09-01 23:34:30 -04:00
myk002 42d3620ef6
update changelog 2021-09-01 13:04:13 -07:00
lethosor 687b84378d
Merge remote-tracking branch 'ab9rf/autofarm-berry-fix' into develop 2021-08-31 00:52:18 -04:00
lethosor dc86460238
Fix dashes in changelog 2021-08-31 00:28:04 -04:00
lethosor 10db894d99
Merge remote-tracking branch 'myk002/myk_printall_nontable' into develop 2021-08-21 22:51:35 -04:00
myk002 4046e06056
update changelog 2021-08-19 21:58:26 -07:00
myk002 51cc8df40c
update changelog 2021-08-19 21:57:14 -07:00
myk002 d3fdb5a6e0
update changelog 2021-08-19 17:44:06 -07:00
lethosor 6b83a39f52
Merge remote-tracking branch 'myk002/myk_orders_reactions' into develop 2021-08-17 00:26:02 -04:00
Kelly Kinkade 22bcbf9877
Merge branch 'develop' into autofarm-berry-fix 2021-08-16 07:22:11 -05:00
Kelly Kinkade 92f258bdbf
Merge branch 'develop' into tailor-v2 2021-08-16 07:17:53 -05:00
myk002 e1f0e94f0f fix changelog 2021-08-14 21:38:00 -07:00
myk002 1e2732aee5 update changelog 2021-08-14 21:38:00 -07:00
myk002 00adb1b720
update changelog 2021-08-14 16:36:09 -07:00
myk002 2bd43f6e76
update changelog 2021-08-14 16:35:34 -07:00
lethosor 77e0938dd1
Merge remote-tracking branch 'ab9rf/autogems-1263' into develop
Conflicts:
	docs/changelog.txt
2021-08-12 00:27:26 -04:00
Kelly Kinkade aec9649c4e
Update changelog.txt 2021-08-11 13:04:55 -05:00
Kelly Kinkade 8254b96498
update changelog 2021-08-11 13:03:28 -05:00
Kelly Kinkade 1e44f61060
update changelog 2021-08-11 13:01:52 -05:00
lethosor 0aeb107844
Update changelog (#1923) 2021-08-11 11:21:41 -04:00
lethosor 0140ace317
Merge remote-tracking branch 'myk002/myk_buildingplan_attached' into develop 2021-08-10 01:07:35 -04:00
myk002 063c512389
update changelog 2021-08-06 07:10:22 -07:00
myk002 9e8a35d263
update changelog 2021-07-30 13:09:14 -07:00
myk002 17017bb526 update changelog 2021-07-30 07:16:03 -07:00
myk002 fca8bffaa4
update changelog 2021-07-21 21:58:06 -07:00
myk002 d12e6fc91e
update changelog 2021-07-09 22:01:47 -07:00
myk002 9deb4cd3e1
update changelog 2021-07-09 21:58:32 -07:00
lethosor dde589967a
Bump to 0.47.05-r2, update changelog 2021-07-09 21:21:36 -04:00
lethosor 8689a019f5
Merge remote-tracking branch 'arzyu/patch-1' into develop 2021-07-05 15:56:37 -04:00
lethosor f33db33c8f
Merge remote-tracking branch 'myk002/myk_force_extents' into develop + add extra changelog note
Conflicts:
	docs/changelog.txt
2021-07-05 15:52:03 -04:00
lethosor 9b58fa45ff
Update changelog (#1881) 2021-07-05 15:42:19 -04:00
lethosor 3e6cecbbc6
Merge remote-tracking branch 'myk002/myk_argparse' into develop 2021-07-05 15:21:59 -04:00
lethosor 887362a6ec
Update changelog (#1877) 2021-07-05 11:45:02 -04:00
lethosor 8da31dbbdc
Reword changelog (#1870) 2021-07-04 21:21:17 -04:00
lethosor ed03df7dfb
Merge remote-tracking branch 'PatrikLundell/embark-assistant' into develop 2021-07-04 21:20:09 -04:00
myk002 b6e6f2d2fe
update changelog 2021-07-03 16:47:49 -07:00
myk002 e1c8bdafba
fix typo in changelog 2021-07-03 11:55:54 -07:00
myk002 37e8dd4a10
update changelog 2021-07-02 23:26:43 -07:00
myk002 db0614d85b
update changelog 2021-06-30 15:00:45 -07:00
myk002 a6a9704631
update changelog 2021-06-29 12:25:21 -07:00
lethosor e070f4d9d8
Merge remote-tracking branch 'myk002/myk_sidebar' into develop 2021-06-28 01:03:13 -04:00
lethosor 96dd249be0
getAnyPlant: use Maps::getPlantAtTile
Followup to #1882
2021-06-25 01:08:58 -04:00
Ryan Williams 35d32645fc
Added getPlantAtTile to Lua API 2021-06-23 23:12:53 -07:00
lethosor e6729894ab
Merge remote-tracking branch 'myk002/myk_delay_until' into develop 2021-06-24 01:05:41 -04:00
myk002 7793adb888
update changelog 2021-06-23 14:55:42 -07:00
myk002 3ca80c271d
update changelog 2021-06-23 14:01:23 -07:00
myk002 d1796effd6
update changelog 2021-06-23 12:32:25 -07:00
arzyu c36441142a update changelog 2021-06-23 23:53:06 +08:00
lethosor 2fc5fbacb5
Merge remote-tracking branch 'myk002/myk_reveal_unhideFlood' into develop 2021-06-19 01:08:05 -04:00
lethosor db7eb9a736
Update scripts, move changelog entry 2021-06-18 18:22:53 -04:00
lethosor a300c5592d
Merge remote-tracking branch 'myk002/myk_teleport' into develop 2021-06-18 18:21:49 -04:00
PatrikLundell ba5915b866 embark-assistant early waterfall quit removed 2021-06-13 17:47:15 +02:00
myk002 473b8245b2
update changelog 2021-06-07 07:04:23 -07:00
lethosor e90e3ae55b
Update changelog
Ref dfhack/stonesense#76, dfhack/stonesense#78
2021-06-06 23:33:20 -04:00
myk002 34aa62d675
update changelog 2021-06-06 08:50:28 -07:00
lethosor bce6432ea6
Merge remote-tracking branch 'bseiller/ea_improve_survey_performance_by_changing_inorgancs_to_vector_int' into develop 2021-06-04 00:21:34 -04:00
myk002 0c44e7da67
update changelog 2021-06-02 14:52:33 -07:00
myk002 b021edda0f
update changelog 2021-06-01 04:45:22 -07:00
lethosor 4f976a5909
Merge remote-tracking branch 'myk002/myk_blueprint' into develop 2021-05-24 23:48:21 -04:00
bseiller 838285e925 Improve performance of surveying => faster search
- def.h: changed vectors for inorganics to contain uint8_t instead of bool which improves the performance when using std::fill and std::memset to batch-set the whole array
- survey.cpp: using std::memset instead of direct assignment to reset the inorganic vectors, also using the actual size of each vector for the call
- changelog.txt: add note concerning the changes
2021-05-23 11:28:48 +02:00
lethosor 001e608aa7
Fix invalid role name
Resolves #1851

See https://github.com/sphinx-doc/sphinx/pull/8345 for details
2021-05-11 19:46:01 -04:00
myk002 aba40b6c44
update changelog 2021-05-10 21:11:13 -07:00
Myk 654b3e9c56
Merge branch 'develop' into myk_negative_number_params 2021-05-09 21:46:07 -07:00
lethosor c07ca1f324
Update changelog (#1826, #1824) 2021-05-10 00:27:21 -04:00
lethosor dc1cfb32b9
Adjust changelog 2021-05-10 00:15:41 -04:00
lethosor 57f26b6f21
Merge remote-tracking branch 'myk002/myk_buildingplan_enable_check' into develop 2021-05-10 00:11:36 -04:00
myk002 26b1489235
make isPlanModeEnabled() consider enable_all 2021-05-08 07:41:08 -07:00
myk002 59b08e99f6
fix -- handling and required arg detection 2021-05-07 15:21:45 -07:00
myk002 fd735d4b42
treat negative numbers as non-options in getopt 2021-05-07 15:21:45 -07:00
myk002 7060c297a8
disable fortress mode tests in CI for now
until we get a reuable fortress save set up
2021-05-07 15:19:10 -07:00
myk002 f8baba2cfd
update changelog 2021-05-07 15:19:09 -07:00
lethosor d902a59541
Move changelog entry to right section and remove link
Ref #1839: https://github.com/DFHack/dfhack/pull/1839/files#r615517105
2021-04-18 23:43:36 -04:00
myk002 a76c89f198
fix quickfortress stockpiles 2021-04-17 14:14:35 -07:00
lethosor e2d56b9b8f
Merge remote-tracking branch 'lethosor/tweak-hide-priority-improvements' into develop 2021-04-08 23:43:14 -04:00
lethosor 761cf19e99
tweak hide-priority: make toggle state persist across designation menu uses
To reproduce:
1. Enter the `d`esignation menu
2. Press `-+` to change priorities
3. Create a designation
4. Press `Alt-p` to hide priorities
5. Exit and re-enter the designation menu (`Esc`, `d`)

Previously, priorities would be visible again after step 5. With this change, they are not visible until you press `Alt-p` again.

Fixes #1068. Note that this is a relatively unobtrusive fix: selecting a priority with `+-` will still result in priorities being shown again. This is native DF behavior that I am reluctant to override because users of designation priorities likely want to see them.
2021-04-05 21:58:51 -04:00
myk002 81bfdf4182
update changelog 2021-04-04 17:40:59 -07:00
lethosor dfb52a2aba
Merge remote-tracking branch 'lethosor/command-prompt-fix-gui-scripts' into develop
Conflicts:
	docs/changelog.txt
2021-04-02 21:53:14 -04:00
lethosor 257f8dbe00
buildingplan: fix size calculation for constructions
Planning a 4x2 construction with DF's `umkh` keys (i.e. not automaterial's box-select) would previously produce a 5x3 construction instead, for example.
2021-04-01 00:16:54 -04:00
lethosor 5e09fd882d
Fix Painter:viewport()
This works because Painter inherits from ViewRect. Unsure how this went unnoticed.
2021-03-27 16:55:48 -04:00
lethosor d61c4aa234
Merge remote-tracking branch 'myk002/myk_xlsxreader_classes' into develop 2021-03-27 00:10:03 -04:00