Commit Graph
109 Commits
Author SHA1 Message Date
Nico Spiske 153da523d6 Hide bookmarkItemPulling button if currently opened gui is not supported (#419)
* [minor] hide pullBookmarkedItems button if open container is not supported

* [minor] spotless apply
2023-09-08 07:16:37 +02:00
miozune c732361bbc More readable packet IDs (#417) 2023-09-06 11:05:15 +02:00
miozune bdb206b45d Fix world specific settings on MP being also specific to dimension (#414) 2023-08-18 21:42:20 +02:00
Raven Szewczyk aa44a97f80 Partial fix for the NEI custom diagram in recipe tooltip issue (#413) 2023-08-17 10:36:15 +02:00
Nico Spiske 00c4411ec5 Pull bookmarked items from container to player inventory (#410)
* [major] first potential version for basic chests

* [major] added api to register chest/inventory guis for bookmark item pulling

* [minor] added hotkey to pull all bookmarked items

* [major] finished

* [minor] spotless apply

* [minor] removed bak file

* [minor] function cleanup

* [minor] fixed bookmarks being set to 0

* [minor] little oversight

* [minor] private attribute and curly brackets
2023-08-07 15:29:05 +02:00
miozune 4f23d21d37 Fix recipe tooltip crash with BetterQuesting (#409)
* updateBuildScript

* Fix recipe tooltip crash with BetterQuesting
2023-07-28 13:20:45 +02:00
8569431e1d Recipe tooltip fixes (#402)
* Unconditionally override Minecraft.currentScreen when drawing tooltips

* Fix bad item lighting in recipe tooltips

* Update buildscript

* Fix NEI ignoring handler switching on click

Handlers might call Minecraft#displayGuiScreen and overwrite Minecraft.currentScreen, but the height hack would unconditionally undo this again.

* spotlessApply (#404)

Co-authored-by: GitHub GTNH Actions <>

* Attempt to fix CME when opening recipes immediately after load (#403)

* Rename the internal private class HeightHack->CompatibilityHacks to better reflect the new usage.

* Move trueGui assignment down.

* Fix overlay button y offsets

* Fix wrong recipe tooltip background rendering

* Apply spotless

---------

Co-authored-by: Wilhelm Schuster <dev@rot13.io>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-07-23 08:04:31 +02:00
Wilhelm Schuster 5b9c27e253 Fix potential NPE when calling ItemMobSpawner#loadSpawners. (#405) 2023-07-16 14:29:31 +02:00
Raven Szewczyk d613d06471 Attempt to fix CME when opening recipes immediately after load (#403) 2023-07-16 09:00:35 +01:00
65ffbad491 Show a full recipe widget in item tooltips for bookmarked recipes (#398)
* Update buildscript

* Show a full recipe widget in item tooltips for bookmarked recipes

* Make recipe tooltips configurable and only show in the bookmarks panel

* Fix layout relative to tooltip boxes

* Fix wildcard import

* spotlessApply (#401)

Co-authored-by: GitHub GTNH Actions <>

* Fix handler tooltip offsets for new&legacy handlers

* Fix render order to draw crafting tooltips on top of container manager buttons

* Fix wrong mouse Y half-point calculation

* Allow saving recipes with empty item ingredient lists to bookmarks (e.g. fluid-only)

* Fix waila vs. non-waila tooltip offsets

Co-authored-by: Wilhelm Schuster <dev@rot13.io>

---------

Co-authored-by: Wilhelm Schuster <dev@rot13.io>
2023-07-10 17:38:07 +01:00
Wilhelm Schuster 885609720e Extend height hack for legacy recipe handlers (#395)
* Store heighthackhandlers.cfg as an internal asset instead of an array of strings

Is copied into the config directory upon first launch. Also, comments
are now allowed (only from the beginning of the file).

* Store serialhandlers.cfg as an internal asset instead of an array of strings

Is copied into the config directory upon first launch. Also, comments
are now allowed (only from the beginning of the file).

Removes GTNH-specific code to be replaced with a configuration file.

* Extend the height hack to also cover guiTop and getRecipePosition

Certain legacy recipe handlers hardcode even more of the NEI recipe
screen layout, requiring only the singular recipe handler switcher
widget at the top, whereas this improved NEI moves the recipe pager to
the top as well expecting recipe handler to move down another 16px. One
such mod that breaks is Immersive Engineering. To fix it we move the top
edge of the gui (guiTop) down by 16px so that the old gap calculation
works correctly. This required special handling in getRecipePosition()
and refreshSlots().

* Fix Immersive Engineering recipe handlers

* Fix Ex Nihilo recipe handlers

* Fix Thermal Expansion recipe handlers

These handlers expect only two recipes to be displayed at a time. This can only be fixed through asm AFAICT.
2023-07-08 23:23:19 +02:00
chochemandglowredman bacf246504 Adjust nei overlay to gt oregen changes (#391)
* adjust to oregen changes

* add compat for old worlds

* remove testing debug

* Update buildscript

* Adjust to changed oregenPattern API

* fix fieldname

---------

Co-authored-by: glowredman <35727266+glowredman@users.noreply.github.com>
2023-07-04 18:36:35 +02:00
Wilhelm Schuster 1ab3350eb8 Adjust recipe handler scrolling again (#393)
* Update buildscript

* Rework recipe handler tab scrolling again

Move the recipe handler tab scrolling before the handler-specific
scrolling again. This ensures that tab scrolling while hovering over the
tab bar will always be possible, regardless of how a recipe handler
handles scrolling itself. This mostly reverts back to how this feature
was implemented originally with one change: the Shift-scrolling behavior
is moved outside the recipe tabs scroll handler after the recipe
handler-specific scroll handling to prevent this from overwriting any
other behavior.
2023-06-24 12:01:21 +02:00
Wilhelm Schuster f3aa12483d Expand the tooltips for the time manipulation action buttons (#392) 2023-06-15 23:19:57 +02:00
miozune d86c472790 Fix crash with IC2 setItemDamage (#387)
* Ducttape fix for crash with IC2 setItemDamage

* Use Items.feather
2023-06-01 07:20:24 +02:00
Wilhelm Schuster 4124151208 Prevent recipe handler tab scrolling from overwriting recipe handler-specific scrolling (#384)
* Rename variable in GuiRecipeTabs to avoid confusion

Based on feedback in a previous PR review.

* Make sure recipe handler-specific scrolling behavior takes precedence over recipe handler tab scrolling
2023-05-13 17:40:08 +02:00
Wilhelm Schuster 2c7207485d Ensure the NEI config is really only initialized once (#381)
bootNEI() is supposed to only be called once during the client's
lifetime. Turns out, if your pack has 800 mods, bootNEI() might be
called a second time before configLoaded is set to true at the end of
the plugin loading thread. This introduces a second variable that is
set at the end of the single threaded portion of bootNEI() so that it
truly can only be called once, but we can still retain the ability to
check if the plugin loading thread has finished.
2023-05-10 23:55:45 +02:00
Wilhelm Schuster e8094794c3 Allow scrolling through recipe handlers (#379)
In addition to scrolling through all recipes of a single handler, you
can now scroll through all the recipe handlers while hovering over the
handler tab bar (or anywhere in the recipe area while holding left
shift).
2023-05-09 21:57:27 +02:00
miozune ad86d8f9c5 Separate logic to get detailed string of fluid amount (#378)
* Separate logic to get detailed string of fluid amount

* updateBuildScript & spotlessApply

* probably better way
2023-05-07 20:10:18 +02:00
Wilhelm Schuster 30c87e9160 Make sure NEI plugins are loaded before processing keybindings (#375)
NEI plugins are initialized in a separate thread. If this takes too long,
the client tick handler might already be running checking the keybindings
in KeyManager while a plugin calls API.addKeyBind() which can lead to a
CME.

Reported in https://github.com/GTNewHorizons/GT-New-Horizons-Modpack/issues/13292
Thanks to @Denostrov for helping me track this down.
2023-05-05 21:01:50 +02:00
Jason Mitchell 0e34840c21 More robust IMC handling (#371)
* Complain if IMC adds a handler/catalyst for a handlerID that doesn't exist.

* Look at the right maps this time

* Don't show matches, only misses
2023-04-16 21:22:09 +02:00
CaedisandMartin Robertz a12fadb10d Add option to have the search widget under item panel (#364)
* Add option to have the search widget under item panel

* update bs+sa

* Make heights consistent

---------

Co-authored-by: Martin Robertz <dream-master@gmx.net>
2023-04-01 23:16:18 +02:00
Raven Szewczyk 9218e233aa Ignore nonstackables in max overlaid recipe count calculation (#365)
* Update buildscript

* Ignore nonstackables in max overlaid recipe count calculation
2023-03-30 21:47:33 +02:00
Raven Szewczyk 45fea43a4b Fix MissingFileException in <https://github.com/GTNewHorizons/GT-New-Horizons-Modpack/issues/12791> (#360) 2023-03-05 14:11:45 +01:00
miozune 088d9c08a8 Prevent NPE with null value for keybind (#358) 2023-03-03 11:15:13 +01:00
miozune 98547c2bcf Prevent NPE with null overlayHandler (#357) 2023-03-03 11:14:56 +01:00
Raven Szewczyk 02fa633043 Fix mob spawn spots sometimes showing as gray (#355) 2023-03-01 13:39:08 +01:00
r1tsuu 9df6ab0232 MacOS Command key accessibility (#354)
* MacOS Command key accessibility

* MacOS Command key accessibility

* Fixed spotless violation build error

* Fixed RMENU key to RMETA as CTRL on MacOS
2023-02-28 15:53:59 +01:00
Raven Szewczyk 89cc203875 Light/chunk overlay fixes (#353)
* Update buildscript

* Fix mob/chunk overlay rendering at very far x/z coordinates

Closes <https://github.com/GTNewHorizons/GT-New-Horizons-Modpack/issues/12680>

* Use Tesselator for mob spawn overlay drawing for a minor performance boost

* Missed a couple of offsets in the other chunk overlay modes
2023-02-27 13:31:44 +01:00
asdflj 4b247d08a5 add more api (#352) 2023-02-15 11:55:16 +01:00
miozune 74b9f8339a Require shift by default for moving items with overlaying recipe (#351) 2023-02-13 07:26:28 +01:00
miozune e20756a196 Don't require holding shift to move items when overlaying recipe (#348)
* updateBuildScript

* Remove redundant public modifier

* Don't require holding shift to move items when overlaying recipe
2023-02-09 11:21:30 +01:00
miozune 6d0f83c499 Make recipe query load all the uncrashed handlers instead of all-or-nothing if one of the handlers crashed (#347)
* Make recipe query load all the uncrashed handlers instead of all-or-nothing if one of the handlers crashed

* better error handling
2023-02-08 08:54:43 +01:00
miozune 8e219c06be Add JEI styled cycle ingredients (#346) 2023-02-05 16:57:09 +01:00
miozune 3fc576b6fc Add more error message for crash with recipe lookup (#345) 2023-02-05 11:27:52 +01:00
miozune 249cb2b308 Allow using hash for tooltip pagination keybind (#344) 2023-02-04 10:35:36 +01:00
miozune e8d8c1994b Add tooltip pagination (#343) 2023-02-03 15:35:03 +01:00
Raven Szewczyk 46a159d788 Update buildscript, dependencies and modid injection shenanigans 2023-01-30 11:53:56 +00:00
Jason Mitchell f106b5e766 [ci skip] spotlessApply with the new settings 2023-01-28 17:55:51 -08:00
Raven Szewczyk e133afc774 Fix jar resource loading on newer Java versions (still works on 8) (#337) 2023-01-25 20:50:48 +01:00
asdflj 75ff631f16 bookmark item stack size readable conversion (#335) 2023-01-23 10:59:29 +01:00
miozune fb51475bb9 Fix stack size of permutations on PositionedStack (#327) 2022-12-26 19:14:45 +01:00
miozune 8c4d609e4c Expose some members in GuiContainerManager (#324) 2022-12-21 10:37:43 +01:00
miozune 336c7dc621 Fix inventory desync when closing GuiRecipe (#320) 2022-11-29 18:21:45 +01:00
makamys 95b437e5c9 Only mark item list as dirty if it's actually modified (#316)
Fixes #315
2022-10-23 11:53:29 +02:00
miozune afe3c54c29 Add config to not optimize computation for GUI overlap (#314) 2022-10-17 20:59:14 +02:00
Jason MitchellandGitHub GTNH Actions 2cab09e91b Try/Catch AIOBE - maybe fixes #295 (#312)
* Try/Catch AIOBE - maybe fixes #295

* spotlessApply

Co-authored-by: GitHub GTNH Actions <unknown>
2022-10-17 11:34:06 +02:00
slprimeandslprime 2302dac5c0 Bookmarks: save result that has output bigger than 64 (#308)
Co-authored-by: slprime <history-21@yandex.ru>
2022-10-13 20:49:43 +02:00
slprimeandslprime 7c2fb2df5f fix bookmarks (#307)
Co-authored-by: slprime <history-21@yandex.ru>
2022-10-13 10:06:08 +02:00
miozune 138d25dbfd Fix incorrect color applied to GuiRecipeCatalyst (#300) 2022-09-19 05:58:46 +02:00