012b668537
Avoid bogus assumptions about block and item NBT on tiles
2022-07-17 21:23:41 +01:00
2ba51567d8
RuntimeBlockMapping: avoid keeping two copies of the same blockstate data in memory
2022-07-10 17:41:01 +01:00
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
7994da07be
Crafting recipe network serialization no longer depends on PM's internal legacy metadata
...
WOOOOOOOOOOOOOOOOOOOOOOHOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO!!!!!!!!!!!!!!!!!!!!!
2022-07-02 16:37:43 +01:00
680615eed8
Namespace rename
2022-06-08 15:54:45 +01:00
1ff69136a3
Merge branch 'next-major' into modern-world-support
2022-06-07 20:01:40 +01:00
38d6284671
Use PHP-CS-Fixer to enforce file header presence
2022-06-04 17:34:49 +01:00
6eac2ea7a5
Modernize private property declarations in src/network
2022-05-17 21:22:33 +01:00
1a598bdfd8
RuntimeBlockMapping: make constructor more useful
...
this allows providing more customisable data sources.
2022-05-12 21:20:28 +01:00
37f0ccdb7e
fix CS
2022-04-20 14:58:57 +01:00
e383f6d8f8
Merge branch 'next-major' into modern-world-support
2022-04-20 14:29:22 +01:00
6b4687a36b
RuntimeBlockMapping: unseal constructor to facilitate easier testing of new versions
2022-04-20 14:00:20 +01:00
63b2e7cc4f
fix CS
2022-04-15 19:25:39 +01:00
c1c3475e5a
RuntimeBlockMapping: reuse the state ID for unknown blocks
...
this doesn't really provide any meaningful benefit, unless there are a very large number of unrecognized states
2022-04-15 19:06:56 +01:00
e58b3ba46c
First look at loading 1.13+ worlds
2022-02-07 03:06:59 +00:00
dd3b79b142
phpstorm sucks
2022-02-07 02:50:43 +00:00
863f9560b0
RuntimeBlockMapping: make fallbackStateData not useless
2022-02-07 02:49:19 +00:00
f870568e62
fix RuntimeBlockMapping
2022-02-07 02:46:50 +00:00
d55eed803d
make build green
2022-02-05 21:12:11 +00:00
f4f4ea1483
fix CS
2022-02-01 17:44:12 +00:00
979f6f3d57
Rewrite RuntimeBlockMapping to use BlockStateSerializer
2022-02-01 17:34:32 +00:00
889d048ca3
Make use of Utils::assumeNotFalse() in a bunch of places
...
I've stuck to only doing this in the places where I'm sure we should never get false back. Other places I'm less sure of (and I found more bugs along the way).
2021-12-08 19:39:04 +00:00
275f145418
BedrockData is now a Composer dependency
...
this should put a stop to people nagging me about incorrect blocks (we have a check to make sure composer dependencies are up to date).
2021-11-02 16:45:45 +00:00
1bbf739385
the function stringToLegacy gives already null useless to put a default null ( #4338 )
2021-07-31 16:54:31 +01:00
1ad38d499c
Deglobalize ItemTypeDictionary usage, at least for the protocol
...
while this is a bit hacky outside of the protocol namespace, it makes it much easier to use the protocol library for alternative purposes, such as for a client or MITM proxy.
It also removes all but one remaining core dependency of the protocol library, making it very close to being able to be separated from the server core entirely.
2021-07-14 14:26:32 +01:00
32d7b1e6af
Start using webmozart/pathutil for joining paths ( #4287 )
2021-06-29 19:40:43 +01:00
61c59be299
Replace hardcoded block metadata shifts and masks with constants
...
we might want to make these bigger than 4 bits in the future.
2021-06-16 12:48:09 +01:00
af1fe7c293
Merge branch 'stable'
2020-11-21 21:13:48 +00:00
3b4e9eea96
RuntimeBlockMapping: drop useless doc comment
2020-09-25 17:43:00 +01:00
5661d0496f
RuntimeBlockMapping::toRuntimeId() now accepts a single integer instead of id/meta
...
the expectation is that eventually this will receive arbitrary internal runtime IDs instead of static id/meta, and RuntimeBlockMapping doesn't really care about this crap anyway.
2020-09-20 12:16:11 +01:00
7e6adc41f0
Merge 1.16 support into PM4 (with changes)
2020-06-26 22:21:09 +01:00
a686840e5e
RuntimeBlockMapping: fixed palette cache never being initialized
...
I must have been very tired when I wrote this code
2020-06-17 21:33:56 +01:00
333ed8ed2f
RuntimeBlockMapping: remove unnecessary nullable flag
2020-06-17 21:32:51 +01:00
07f979fbde
RuntimeBlockMapping: bedrockKnownStates is never null
2020-05-18 17:54:27 +01:00
6b037d6a4c
RuntimeBlockMapping: these IDs are not static any more
2020-05-11 12:40:55 +01:00
f9a587d40e
imports cleanup
2020-04-28 17:27:38 +01:00
a97cafd4f6
moving serializers into protocol namespace
2020-04-27 13:54:39 +01:00
a75241ef03
RuntimeBlockMapping: use SingletonTrait
2020-04-24 21:32:47 +01:00
3a42c21cc1
wrap up block_id_map in a class
2020-04-24 21:28:27 +01:00
ff915b829c
StartGamePacket: remove hardcoded cache, move to RuntimeBlockMapping
2020-04-24 20:50:56 +01:00
287bf4274f
move RuntimeBlockMapping to convert package
2020-04-24 12:42:43 +01:00