Commit Graph

432 Commits

Author SHA1 Message Date
Dylan K. Taylor
99faeb8d05 Merge remote-tracking branch 'origin/stable' into next-minor 2022-12-19 15:55:59 +00:00
Dylan K. Taylor
529700bb8b PotionTypeIdMap: fixed uninitialized fields
I have no idea why this didn't ever cause a problem before... probably an edge-case in the typed properties implementation
2022-12-19 15:33:15 +00:00
IvanCraft623
44e288554a Implement new records (#5433) 2022-12-18 21:15:27 +00:00
Dylan K. Taylor
4d79aced07 Merge branch 'next-minor' into next-major 2022-12-15 19:50:27 +00:00
Dylan K. Taylor
18c2e90574 fix CS 2022-12-05 14:47:44 +00:00
Dylan K. Taylor
142ccc7e87 Merge branch 'next-minor' into next-major 2022-12-05 14:14:39 +00:00
Dylan K. Taylor
ca3b5c38b7 Added internal support for tag recipe ingredients 2022-12-02 14:03:58 +00:00
Javier León
3984d220bb Implemented the swift sneak enchantment (#5404)
Co-authored-by: Dylan T <dktapps@pmmp.io>

closes #5301
2022-12-01 20:38:41 +00:00
ipad54
858d3dce8e Implement Weeping & Twisting vines (#5396) 2022-11-15 15:29:42 +00:00
Dylan K. Taylor
a205d64732 Merge branch 'next-minor' into next-major 2022-11-12 17:02:56 +00:00
Javier León
d03bbb0426 Implemented darkness effect (#5402) 2022-11-10 12:57:14 +00:00
Dylan K. Taylor
7bcc663b60 Migrate core code to using symfony/filesystem
webmozart/path-util is retained for plugin compatibility, but is dropped in 5.0
2022-10-14 21:51:29 +01:00
Dylan K. Taylor
f88ae93897 BC break: Replaced webmozart/path-util with symfony/filesystem, closes #5332 2022-10-13 16:43:36 +01:00
IvanCraft623
1366a43c22 Implement Turtle Shell (#5235) 2022-09-28 18:19:15 +01:00
Dylan K. Taylor
1bc8fb1851 BlockStateToObjectDeserializer: reduce code duplication in legacy slab handling 2022-09-24 16:32:02 +01:00
Dylan K. Taylor
1609b11c8e Make blockstate (de)serializer names a bit less verbose 2022-09-24 13:43:00 +01:00
Dylan K. Taylor
cf9610c710 BlockStateToBlockObjectDeserializer: added mapSimple() for symmetry's sake
this will also make it marginally easier to switch to a unified system.
2022-09-24 13:41:41 +01:00
Dylan K. Taylor
590eb74703 Make Block(De)Serializer much less nasty to interact with
this makes it a lot less inconvenient to access the primary blockstate serializer/deserializer, which is necessary for registering new blocks.
2022-09-24 13:31:50 +01:00
Dylan K. Taylor
4dabac8420 Merge branch 'next-minor' into next-major 2022-08-27 17:28:06 +01:00
Dylan K. Taylor
7fd4c12ea1 First look at (mostly) unified item serializer registrar
this halves the amount of code needed to implement most items.
2022-08-27 15:10:55 +01:00
Dylan K. Taylor
08b9495bce DyeColorIdMap: fixed uninitialized offset error on invalid dye colours 2022-08-26 18:58:00 +01:00
Dylan K. Taylor
64ac20173b ItemDeserializer: remove unnecessary code
these are legacy IDs and are upgraded to modern IDs before ever reaching this code.
2022-08-26 17:06:09 +01:00
Dylan K. Taylor
ca3612e4ff Preparations for attempted unification of ItemSerializer and ItemDeserializer 2022-08-26 16:18:13 +01:00
IvanCraft623
b65e0f64f6 Implement Suspicious Stew (#5224) 2022-08-16 17:26:32 +01:00
IvanCraft623
223de3ad23 Implement Fire Charge (#5225) 2022-08-15 17:00:58 +01:00
Dylan K. Taylor
d4f96a155a Support axis rotation of Muddy Mangrove Roots (implemented in 1.19.20) 2022-08-14 18:53:01 +01:00
Dylan K. Taylor
43a3151de3 Merge branch 'next-minor' into next-major 2022-08-14 18:49:19 +01:00
Dylan K. Taylor
102406ee79 Added froglights 2022-07-23 17:40:38 +01:00
Dylan K. Taylor
38e495babf Added mangrove roots and muddy mangrove roots 2022-07-23 17:20:23 +01:00
Dylan K. Taylor
b13f333b2e Added mud and packed mud 2022-07-23 16:40:46 +01:00
Dylan K. Taylor
a7313ed9d9 Added rooted dirt 2022-07-23 16:12:17 +01:00
Dylan K. Taylor
67682cbf27 Added chorus plant and flower 2022-07-20 20:19:36 +01:00
Dylan T
c1acf44337 Implement cauldrons (#5163)
the following things are currently not implemented:

- particle/sound effects when an entity extinguishes itself
- particle/sound effects when mixing different stuff in a cauldron
- powder snow cauldron

both of these things are contingent on #5169, but for the time being, the PR is functionally complete and I want to move on to something else without being stalled by the particle+sound problem (which I haven't yet decided how to solve).
2022-07-20 16:12:58 +01:00
Dylan K. Taylor
fa201b081c Added spore blossoms
I got tired of the flood of warning messages every time someone joined the dev server...
2022-07-19 20:28:12 +01:00
Dylan K. Taylor
87b840ff97 Added a hack to allow tiles to trigger client-side render updates on blocks without actually changing the block
Bedrock block entity updates don't directly trigger block rendering
updates. This is a problem when the block entity data affects the
block's appearance directly (e.g. cauldron water colour, flower pot
contents), because it means changing them won't directly result in a
client-side render update.

This hack allows tiles to spoof block updates without actually changing
the server-side block, keeping the internals and API clean of random
shitbox workarounds.

fixes #5174
fixes #4944
2022-07-19 17:47:46 +01:00
Dylan K. Taylor
f64e306fb8 Make BlockIdMetaUpgrader API less dumb
the old impl prevented registering more than one meta -> state mapping since the legacy numeric ID map would throw an exception if attempting to map the same ID more than once.
2022-07-19 16:21:56 +01:00
Dylan K. Taylor
9a8902d1fe LegacyToStringMap: don't throw if the existing mapping is the same as the one we want to register
this was making it inconvenient for plugins to use BlockIdMetaUpgrader->addMapping(), because the block legacy ID map contains IDs up to 1.16, but the table of mapped 1.12 blockstates only goes up to ... well ... 1.12. This left a gap of several versions' blocks unable to be mapped.
2022-07-19 16:08:05 +01:00
Dylan K. Taylor
b36b65927c BlockDataUpgrader: expose BlockIdMetaUpgrader via getter 2022-07-19 16:02:35 +01:00
Dylan K. Taylor
afaf9dbc88 Rename LegacyBlockStateMapper -> BlockIdMetaUpgrader
this more accurately describes what it's used for.
2022-07-19 15:32:08 +01:00
Dylan K. Taylor
b0a492c063 Move simple block (de)serializer registrations into their own functions 2022-07-18 18:47:30 +01:00
Dylan K. Taylor
6d4279671e A giant hack to cut down code needed for runtime block serialization by 50%
this also avoids repeated information and inconsistencies.
2022-07-18 18:25:41 +01:00
Dylan K. Taylor
cf34f88a67 Make Block::decodeState() and encodeState() more codegen-friendly 2022-07-18 15:48:03 +01:00
Dylan K. Taylor
b8d1b00985 phpstan fail very sad :( 2022-07-18 15:26:14 +01:00
Dylan K. Taylor
8660dfe576 Generate traits for runtime enum serialization instead of helper classes 2022-07-18 15:16:33 +01:00
Dylan K. Taylor
07786dc4bc RuntimeDataWriter: fixed doc comment 2022-07-14 22:51:12 +01:00
Dylan K. Taylor
ba2baba7cc Added netherite blocks and items 2022-07-14 20:39:09 +01:00
Dylan K. Taylor
b4ce5ed515 ItemDeserializer: throw a more specific exception on unknown items 2022-07-14 19:16:15 +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
91719051e2 BlockStateToBlockObjectDeserializer: removed TODO mess
these were useful when writing the initial version from scratch; not so much for implementing random blocks
2022-07-14 16:50:08 +01:00
Dylan K. Taylor
d321094081 Added hanging roots 2022-07-14 16:47:55 +01:00