Commit Graph

1190 Commits

Author SHA1 Message Date
Dylan K. Taylor
e5804df24b Merge branch 'next-minor' into next-major 2022-07-14 20:59:13 +01:00
Dylan K. Taylor
e00f8e3a32 Merge branch 'stable' into next-minor 2022-07-14 20:59:06 +01:00
Dylan K. Taylor
c8320fe849 Merge branch 'next-minor' into next-major 2022-07-14 20:50:49 +01:00
Dylan K. Taylor
e2855aadff Simplify handling of broken transactions for crafting and friends
this allows stuff like smithing tables to work without needing any extra hacks.

Implementing enchanting or anvils would require some extra work, but I don't plan to implement those under the legacy transaction system anyway.
2022-07-14 20:50:06 +01:00
Dylan K. Taylor
c7133bc2e6 InGamePacketHandler: don't kick the player out of inventory windows on actor events
this is sent when the player crafts something using an anvil.
2022-07-14 20:36:11 +01:00
Dylan K. Taylor
eb8fb63409 Added cartography and smithing tables
these have working inventories, and their crafting menus will 'just work' once the items for the associated recipes have been implemented (maps, netherite).
2022-07-14 18:01:47 +01:00
Dylan K. Taylor
dea0207e4e Merge branch 'next-minor' into next-major 2022-07-13 17:06:04 +01:00
Dylan K. Taylor
06655bee78 Updated to 1.19.10 2022-07-13 00:59:49 +01:00
Dylan K. Taylor
2ba51567d8 RuntimeBlockMapping: avoid keeping two copies of the same blockstate data in memory 2022-07-10 17:41:01 +01:00
Dylan K. Taylor
ccb3c3cb05 BlockStateData: use array<Tag> instead of CompoundTag to store state properties
this reduces the footprint of RuntimeBlockMapping by a further 1 MB, as well as simplifying various parts of the code, and solidifying the immutability guarantee of BlockStateData.
2022-07-09 16:03:51 +01:00
Dylan K. Taylor
151f2c3f3a BlockStateDictionary: reduce memory footprint by 5 MB by deduplicating blockstate NBT keys and values 2022-07-08 21:51:44 +01:00
Dylan K. Taylor
a8728a02f6 BlockStateDictionary: extract a more generic helper method for decoding block palette files 2022-07-06 14:37:46 +01:00
Dylan K. Taylor
68cbe46600 Exterminate legacy item IDs 2022-07-05 15:12:55 +01:00
Dylan K. Taylor
9f0b32e748 Updated creative and crafting data to 1.19 2022-07-04 20:28:07 +01:00
Dylan K. Taylor
405e552efd ItemTranslator: use GlobalItemDataHandlers
this ensures that plugin serializers will actually be used on the network.
2022-07-04 15:47:28 +01:00
Dylan K. Taylor
d9c61f0492 Publish script used to generate ItemTypeIds 2022-07-04 15:43:13 +01:00
Dylan K. Taylor
323c563684 Break Block's dependence on ItemFactory, and item legacy IDs
let's GOOOOOOOOOOOOOOOOOOOOOOOOOOOOO
2022-07-02 17:29:28 +01:00
Dylan K. Taylor
7994da07be Crafting recipe network serialization no longer depends on PM's internal legacy metadata
WOOOOOOOOOOOOOOOOOOOOOOHOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO!!!!!!!!!!!!!!!!!!!!!
2022-07-02 16:37:43 +01:00
Dylan K. Taylor
5e4e5147d9 Remove ItemFactory involvement from brewing
this involves a very nasty hack for potion container change, but for the time being it can't be helped.
2022-06-29 16:11:15 +01:00
Dylan K. Taylor
2cb722b674 Fixed durability handling (ish) 2022-06-29 15:17:16 +01:00
Dylan K. Taylor
541a624d48 ItemFactory::get() now consistently throws SavedDataLoadingException on any error, including unknown items 2022-06-27 17:14:43 +01:00
Dylan K. Taylor
55cb68e5b5 Burn meta wildcards from Item, allow more dynamic recipe inputs
this was an obstacle for getting rid of legacy item IDs.
2022-06-27 13:33:26 +01:00
Dylan K. Taylor
bc5a600d59 Added item stack serialize/deserialize methods 2022-06-26 17:02:55 +01:00
Dylan K. Taylor
301b0aba82 Allow Item (de)serializer to accept dynamic BlockState(De)Serializer 2022-06-08 16:22:35 +01:00
Dylan K. Taylor
680615eed8 Namespace rename 2022-06-08 15:54:45 +01:00
Dylan K. Taylor
cf7d42b3ea Fix CS according to new rules 2022-06-07 20:02:24 +01:00
Dylan K. Taylor
1ff69136a3 Merge branch 'next-major' into modern-world-support 2022-06-07 20:01:40 +01:00
Dylan K. Taylor
aa9f8781ff Merge branch 'next-minor' into next-major 2022-06-07 19:56:26 +01:00
Dylan K. Taylor
4ec97d0f7a InGamePacketHandler: added missing break
I'm getting sloppy ...
2022-06-07 17:52:59 +01:00
Dylan K. Taylor
016a80bb70 1.19.0 changes 2022-06-07 17:47:13 +01:00
Dylan K. Taylor
c29e23b2f1 TypeConverter: port 5fd685e07d to modern-world-support 2022-06-06 22:13:26 +01:00
Dylan K. Taylor
57132204ec ItemTranslator: throw only the expected exception types 2022-06-06 22:09:32 +01:00
Dylan K. Taylor
860fa719b2 ItemTranslator: Accept dynamic BlockStateDictionary instead of using singleton
this will be needed for handling protocol updates in the future
2022-06-06 21:50:43 +01:00
Dylan K. Taylor
c89f7f8e5e TypeConverter: duct tape for crafting recipe block inputs 2022-06-06 21:47:04 +01:00
Dylan K. Taylor
13bb1c26fb ItemTranslator now operates directly using Item, rather than using item ID/meta + ItemFactory
in almost all cases where ItemTranslator is used, an Item already exists, so it doesn't make any sense to make ItemTranslator go and create another item instance just to pass to ‰ItemSerializer.
2022-06-06 20:51:26 +01:00
Dylan K. Taylor
5fd685e07d TypeConverter: fix crash on arbitrary out-of-bounds item IDs
I don't know why I didn't consider this fix necessary when the item meta bug was originally discovered.
2022-06-06 19:29:44 +01:00
Dylan K. Taylor
08fbf92d8d Filter out recipes containing unknown items 2022-06-06 18:25:14 +01:00
Dylan K. Taylor
e040c2b281 InventoryManager: fixed windows not opening when the server removes windows
closes #5094
2022-06-05 16:03:24 +01:00
Dylan K. Taylor
dab7686656 Merge branch 'next-major' into modern-world-support 2022-06-04 18:43:11 +01:00
Dylan K. Taylor
083a35f970 Modernize property type declarations 2022-06-04 18:16:32 +01:00
Dylan K. Taylor
38d6284671 Use PHP-CS-Fixer to enforce file header presence 2022-06-04 17:34:49 +01:00
Dylan K. Taylor
ef15dc883a Merge branch 'next-major' into modern-world-support 2022-06-01 15:34:26 +01:00
Dylan K. Taylor
3fcf6372e0 Merge branch 'stable' into next-minor 2022-06-01 15:32:37 +01:00
Dylan K. Taylor
bf199d3a74 duct tape for recipes 2022-05-27 20:40:32 +01:00
Dylan K. Taylor
2b27b8a230 fixed fucky wucky 2022-05-24 21:52:10 +01:00
Dylan K. Taylor
383be5426e Rewrite network item serialization to use ItemSerializer 2022-05-24 21:44:57 +01:00
Dylan K. Taylor
227f28a6d2 Use VanillaItems::AIR() instead of ItemFactory 2022-05-24 15:47:27 +01:00
Dylan K. Taylor
03c505aaa7 Merge branch 'next-major' into modern-world-support 2022-05-22 16:21:48 +01:00
Dylan K. Taylor
179cac45f5 Merge branch 'stable' into next-minor 2022-05-22 16:21:05 +01:00
Dylan K. Taylor
fcb2ccab99 NetworkSession: Sync all attributes on respawn 2022-05-21 16:22:35 +01:00