shevernitskiy
bd4d831582
add flag for dummy & resolve conflicts
2023-09-24 11:44:04 +03:00
shevernitskiy
25cc778fce
review refactor
2023-09-24 11:44:04 +03:00
shevernitskiy
770402a292
erase from delayed when deleteHandle()
2023-09-24 11:44:04 +03:00
shevernitskiy
033a849de2
Apply suggestions from code review
...
Co-authored-by: Myk <myk.taylor@gmail.com>
2023-09-24 11:44:04 +03:00
shevernitskiy
469a97f781
review
2023-09-24 11:44:04 +03:00
shevernitskiy
5b34ac63e1
fix for gcc
2023-09-24 11:44:03 +03:00
shevernitskiy
6f26650255
reserved texpos range
2023-09-24 11:44:03 +03:00
lethosor
3af118dce9
Check that SDL_ShowSimpleMessageBox has been bound first
...
This function can be called before DFSDL is initialized
2023-09-21 01:18:56 -04:00
lethosor
aa6c4094c5
Use SDL_ShowSimpleMessageBox in Core::fatal()
...
This allows the message to be displayed consistently in a dialog on all platforms.
2023-09-21 01:13:07 -04:00
Myk Taylor
a61b8d11d0
Revert "use osyncstream for writing to gamelog.txt"
...
This reverts commit 4695b8c86d
.
2023-09-17 21:38:48 -07:00
Myk Taylor
4695b8c86d
use osyncstream for writing to gamelog.txt
2023-09-17 21:23:45 -07:00
Myk Taylor
863df21dd2
protect against missing keys param
2023-09-12 23:08:55 -07:00
Myk Taylor
e325f3b6d9
differentiate the new region loading screen in the focus string
2023-09-10 16:32:52 -07:00
Myk Taylor
5a557f232f
disable texture loading if enabler isn't present
2023-09-10 01:42:59 -07:00
Myk Taylor
cbe4f53823
add focus string details for orders context
2023-09-03 12:50:12 -07:00
Myk Taylor
1d6ae37a66
fix and reinstate heat safety filter
2023-09-03 11:54:32 -07:00
Myk Taylor
b8fc6e210f
add note about handling bags
2023-09-03 07:12:30 -07:00
Myk
940d25accb
Merge pull request #3711 from myk002/myk_instrument_textures
...
[Textures] instrument textures module
2023-08-31 18:14:18 -07:00
lethosor
40bfb6b8ff
Hack to force GCC to invoke cancel_job() through DF's vtable
...
GCC appears to be optimizing the call to `cancel_job()` to use the stub in
*DFHack's* job_handler vtable, which is a no-op. Lua was unaffected because it
invokes vmethods through method pointers (without knowing the target instance at
compile time), so use a similar approach here for now.
As mentioned by @ab9rf on Discord, we should pursue an alternative like asking
Bay12 to expose the relevant code through a global `std::function` instead of a
vmethod.
2023-08-31 17:42:16 -04:00
Myk Taylor
088fa9a35c
instrument textures module and clean up gui
2023-08-31 10:53:43 -07:00
Myk
5d7649837c
Merge pull request #3704 from shevernitskiy/create-delete-textures
...
create and delete textures
2023-08-30 03:42:27 -07:00
shevernitskiy
8a015f7f87
review
2023-08-30 07:38:21 +03:00
Myk Taylor
a8bf8a04ae
add in value for units contained in cages
2023-08-28 15:42:56 -07:00
Myk Taylor
423bba2c24
pass getAnyStockpile and getAnyCivZone through ZScreens
2023-08-28 13:27:46 -07:00
shevernitskiy
4b0219e225
fix stupid linux build again
2023-08-28 10:56:08 +03:00
shevernitskiy
51baa0d674
fix linux build
2023-08-28 10:46:59 +03:00
shevernitskiy
6f11812729
create and delete textures
2023-08-28 10:00:39 +03:00
Myk
a740c6628e
Merge pull request #3663 from shevernitskiy/dynamic-texture-loading
...
feat: dynamic texture loading
2023-08-27 22:45:52 -07:00
shevernitskiy
6c5163af9e
adjust adopt region reset step
2023-08-27 22:28:03 +03:00
Myk Taylor
1763a16831
add training check functions to Units
2023-08-20 10:08:25 -07:00
shevernitskiy
c1945f7b54
fix build err in gcc
2023-08-17 06:32:26 +03:00
Myk Taylor
fa3c2222e6
higher granularity for unit viewsheet focus strings
2023-08-13 23:54:18 -07:00
shevernitskiy
91f4c3d561
mirgate preloaded assets to lua
2023-08-14 08:17:57 +03:00
shevernitskiy
1409af67de
expose api to lua
2023-08-13 20:09:12 +03:00
Myk
71e5901214
Merge pull request #3672 from myk002/myk_gui
...
[orders] prevent overlay from appearing on the new workorder page
2023-08-12 23:21:13 -07:00
shevernitskiy
22b0671038
review 2
2023-08-13 08:33:31 +03:00
Myk Taylor
b787c2bb1e
make creating a workorder a subscreen instead of a top-level
2023-08-12 22:02:17 -07:00
Myk Taylor
c37dce7c33
detect extended tile properties and communicate them back to lua
2023-08-12 15:53:22 -07:00
shevernitskiy
687bd82542
pathable & unsuspend specific tile size
2023-08-12 20:05:15 +03:00
shevernitskiy
fe8bd4fa78
assets use dynamic texture loading
2023-08-12 16:11:42 +03:00
Myk Taylor
8d8c139ccb
don't add keys as text when ctrl or alt are pressed
2023-08-11 12:54:49 -07:00
shevernitskiy
e81a90821a
review
2023-08-11 21:40:41 +03:00
shevernitskiy
4bbcc7b05d
eof fix
2023-08-11 09:48:03 +03:00
shevernitskiy
e21f0f2b69
dynamic texture loading
2023-08-11 09:14:05 +03:00
Myk Taylor
03edea8257
add focus string support for legends mode
2023-08-07 02:50:37 -07:00
Myk Taylor
db48e0eba0
remove caravan_buying param from getValue call
...
the identity of the selling party doesn't actually affect the value!
2023-08-06 17:38:34 -07:00
lethosor
eb12ff17f6
Refactor: move static identity_traits to their own file, simplify field defs
...
DataStaticsFields.cpp used to contain identity_traits specializations for
primitive and opaque STL types, as well as macros used for the generated struct
field definitions. Only one of these were actually used in any compilation unit,
and the identity_traits definitions were hidden behind a guard to prevent them
from being compiled at all when building the struct field definitions.
Now, the identity_traits specializations live in their own file,
DataIdentity.cpp (matching their declarations, which live in DataIdentity.h).
This speeds up build times because modifying these specializations no longer
requires rebuilding all of the field definitions unnecessarily.
2023-08-02 00:15:26 -04:00
lethosor
9f168214dd
Merge remote-tracking branch 'lethosor/fix-textures-cleanup-segfault' into develop
2023-08-01 00:35:19 -04:00
lethosor
e2ca506e23
Fix off-by-one error in Textures::cleanup()
...
In a ASCII-only configuration, I was seeing `textures.raws.size() == 164` and
`texpos_end == 164`. This resulted in reading one item past the end of the
vector.
This may not be occurring in configurations with graphics enabled, or
Windows/WINE may be more permissive.
2023-08-01 00:13:09 -04:00
lethosor
e55984c529
Fix startup crashes when global addresses are missing
...
Useful for initial research. Can be tested with `DFHACK_NO_GLOBALS=1`
2023-08-01 00:05:02 -04:00
Myk Taylor
77d0fb297c
convert tabs to spaces when getting clipboard text
...
this avoids tab characters being translated to "?" when converted to
cp437
2023-07-21 15:03:06 -07:00
Myk Taylor
dff4816287
update dwarfvet
2023-07-21 04:12:56 -07:00
Myk Taylor
0d81f5ce6e
don't include dead citizens in the citizens list
2023-07-18 23:09:19 -07:00
Myk
2cd226d879
Merge pull request #3566 from myk002/myk_pasture
...
[zone] initial implementation of pasture assignment screen
2023-07-16 14:36:57 -07:00
Myk Taylor
5fb299c6df
expand egg-laying filter to the entire race, not just the unit
2023-07-16 12:30:12 -07:00
Myk Taylor
39612f0d5a
trade a bin if any contents can be traded
...
the new trade screens will make it easy to filter out unwanted items
later
2023-07-16 12:15:51 -07:00
Kelly Kinkade
1fba8b16f5
replace `dts:make_unique` with `std::make_unique`
...
2014 here we come!
2023-07-07 21:38:15 -05:00
Myk Taylor
6a8522ab5e
generalize dfhack.items.isRequestedTradeGood
2023-07-06 03:27:05 -07:00
Myk Taylor
b938891e11
add dfhack.items.isRequestedTradeGood
2023-07-06 03:24:36 -07:00
Myk Taylor
c45dcdd7b0
implement sell_prices adjustments
2023-07-06 03:24:16 -07:00
Myk Taylor
2aeb86ba8f
implement trade agreement buy prices
2023-07-06 03:24:16 -07:00
Myk Taylor
c2e647b79b
fix item prices and algorithm
...
adjust prices according to race WAR affinity
2023-07-06 03:24:15 -07:00
Myk Taylor
9849885df6
Revert "generalize dfhack.items.isRequestedTradeGood"
...
This reverts commit aa6d28bab6
.
2023-07-06 03:23:17 -07:00
Myk Taylor
aa6d28bab6
generalize dfhack.items.isRequestedTradeGood
2023-07-06 03:21:36 -07:00
Myk
79dbcf0461
Merge pull request #3524 from myk002/myk_copypaste
...
support copy/paste from system clipboard
2023-07-05 23:09:08 -07:00
Myk
785405b281
Update DFSDL.cpp
2023-07-05 22:34:25 -07:00
Myk
50b3cecfcf
Merge pull request #3481 from myk002/myk_cpp20
...
get compiling with c++-20
2023-07-05 22:28:59 -07:00
Myk
c25b6e642e
Merge pull request #3533 from myk002/myk_noble
...
port API for unit lookup by noble role from quickfort
2023-07-05 19:34:29 -07:00
Myk Taylor
c587cad471
generalize to civ roles as well
2023-07-05 17:37:49 -07:00
Myk
8e7d7fefc0
Merge pull request #3527 from myk002/myk_no_extra_keys
...
filter out spurious STRING keybindings
2023-07-05 12:10:51 -07:00
Myk Taylor
43ea9b94c3
move clipboard wrappers into DFSDL module (but not in the namespace)
2023-07-05 12:08:18 -07:00
Myk Taylor
125e4c623b
avoid inducing link dependency on dfhack
2023-07-05 11:07:51 -07:00
Myk Taylor
cbdb56a1ac
port API for unit lookup by noble role from quickfort
2023-07-03 13:47:43 -07:00
Myk Taylor
f111b69f2f
Merge branch 'develop' into myk_cpp20
2023-07-03 11:49:54 -07:00
Myk Taylor
9ca96567a5
move conversion logic to MiscUtils
...
but keep minimal wrappers in SDL module so we don't leak memory
2023-07-03 11:05:58 -07:00
Myk Taylor
fdf2430fc4
filter out spurious STRING keybindings
...
that don't match actual SDL string input
2023-07-03 09:09:52 -07:00
Myk Taylor
c660a12502
differentiate between choosing merchant screen and default trade screen
2023-07-02 19:09:15 -07:00
Myk Taylor
d39440d33b
migrate markForTrade logic from logistics to core
2023-07-02 19:05:50 -07:00
Myk Taylor
acd03486a9
add some more detail to the focus strings for buildings
2023-07-02 19:05:50 -07:00
Myk Taylor
175c249d29
support copy/paste from system clipboard
2023-07-02 18:04:06 -07:00
Myk Taylor
e308d3204a
Merge branch 'develop' into sdl2
2023-06-26 16:04:50 -07:00
Myk Taylor
b5f4cef187
differentiate trade request screen from other diplomacy screens
2023-06-26 02:29:36 -07:00
Myk Taylor
8235680ff0
add unsuspend map textures
2023-06-25 18:40:04 -07:00
Myk Taylor
78448f438d
don't leak warning suppression out of protobuf
2023-06-25 17:53:16 -07:00
Myk
b958727655
Update Textures.cpp
2023-06-23 14:36:26 -07:00
Myk Taylor
f7bef53b42
prefer symbols to descriptions for hotkey names
2023-06-23 14:36:18 -07:00
Myk Taylor
840a2b3525
ensure DFHack screens get all string input
2023-06-23 14:36:18 -07:00
Taxi Service
3e2940ef8f
attempt to set optional tilesize arguments for load_texture()
2023-06-23 14:35:45 -07:00
Myk Taylor
52151b0e98
remove SDL functions that don't exist anymore
2023-06-23 14:31:14 -07:00
Myk Taylor
4e48ce64f1
get things mostly ported to SDL2
2023-06-23 14:31:12 -07:00
Myk Taylor
b571e5b52b
don't diplay orders overlay on subscreens
2023-06-19 16:48:07 -07:00
Myk Taylor
8a079e1ae7
get compiling on windows
2023-06-17 22:14:11 -07:00
Myk Taylor
2efef75b4e
re-constify
2023-06-17 10:46:56 -07:00
Myk Taylor
4a2b97105c
only initialize steam if launched from steam
2023-06-05 14:18:55 -07:00
Myk Taylor
5c914280c3
change dynamic_cast -> virtual_cast
2023-06-01 10:53:08 -07:00
Myk Taylor
974a6155c0
reinstated Buildings.setOwner
2023-05-31 18:48:08 -07:00
Myk Taylor
8b3eef699f
adjust findCivzonesAt to v50 semantics
2023-05-27 05:37:31 -07:00
Myk Taylor
8c01f3efe0
don't relaunch launchdf if it's already running
2023-05-20 02:59:41 -07:00
Myk Taylor
a5a6b70a51
launch DFHack through steam if DF is run from steam
2023-05-20 02:59:39 -07:00
Myk Taylor
11361975f9
look up texpos values instead of assuming they're constant
2023-05-16 17:14:36 -07:00