MineClone2/mods/ENTITIES
sfan5 693a5317ef Fix non-serializable item entity unload crash
Some items, like shulkers or books, can have so much metadata that the
corresponding item entity can not be serialized by the Minetest engine.

Without this patch, dropping such an item and then moving away crashes
Minetest, as it can not serialize the entity with serializeString16()
when unloading a map block.

The patch resets the overlong metadata of non-serializable item entities.
This avoids a crash and makes it possible to retrieve a “sanitized” item
without metadata when the mapblock containing the item entity is reloaded.

Originally sfan5 guessed the maximum possible item entity serialization size
that would not lead to a crash as 65530 bytes, but anon5 calculated it to be
actually 65487 bytes. This has been experimentally verified by erlehmann.
2021-09-15 18:10:32 +02:00
..
drippingwater [drippingwater] fix warnings 2021-05-25 00:54:12 +02:00
mcl_boats Merge pull request 'Title HUD API' (#1778) from title-API into master 2021-08-20 12:31:54 +00:00
mcl_burning fix many codestyle issues (functions, strings, modpaths) 2021-05-29 16:12:33 +02:00
mcl_falling_nodes Move code of making anvils destroy items when falling 2021-07-05 12:28:14 +00:00
mcl_item_entity Fix non-serializable item entity unload crash 2021-09-15 18:10:32 +02:00
mcl_minecarts Merge pull request 'Title HUD API' (#1778) from title-API into master 2021-08-20 12:31:54 +00:00
mcl_mobs [mcl_mobs/api] Add mob flow code from Crafter 2021-06-22 05:10:45 +04:00
mcl_paintings Merge branch 'master' into polish-translation 2021-06-02 10:14:25 +00:00
mobs_mc Merge pull request 'Added spawn egg for killer rabbit' (#1704) from talamh/MineClone2:master into master 2021-09-04 10:21:18 +00:00
mobs_mc_gameconfig [mobs_mc_gameconfig] fix warning 2021-05-23 14:54:20 +02:00
modpack.conf Add a couple of modpack.conf files 2019-01-07 00:52:05 +01:00