Commit Graph

159 Commits

Author SHA1 Message Date
AFCMS
96e83e866c
Make mcl_item_entity API public 2022-11-15 21:48:58 +01:00
AFCMS
3bb86fd436
Fix warnings + add type annotations
- fix wrong usage of `mcl_enchanting.get_enchantments`
- use new vectors everywhere
- simplify code
- make code lines less long
2022-11-15 21:48:57 +01:00
ancientmarinerdev
a2732b655f Code cleanup 2022-11-14 04:07:41 +01:00
ancientmarinerdev
9065170b1c Clean up hopper minecart 2022-11-14 04:07:41 +01:00
ancientmarinerdev
ce457eb351 Who doesn't love hopper minecarts? 2022-11-14 04:07:41 +01:00
PrairieWind
d74e61d8b2 Sky's the Limit Advancement 2022-09-14 20:37:08 +00:00
PrairieWind
404f623527 The Next Generation Advancement 2022-09-14 20:37:08 +00:00
cora
2b2ba47aed Fix crash with itementity and unloaded nodes 2022-08-28 21:08:17 +02:00
MysticTempest
6cbedd408e Fix regression of item movement in water transport streams. 2022-08-19 06:53:26 -05:00
Sumyjkl
16c9a83a96 fix items floating into the air under rare circumstances 2022-08-12 21:46:17 +10:00
Sumyjkl
86d6445f42 fix crash when items in unloaded chunk 2022-07-28 11:10:56 +10:00
Sumyjkl
70b7655e46 various code style improvements 2022-07-26 20:20:13 +10:00
Sumyjkl
5fc662664f cactus will act as if dug instead of its own hardcoded breaking function 2022-07-24 15:59:00 +10:00
Sumyjkl
6278fa21d3 Removed an entire block of code that was duplicate and didn't do anything 2022-07-23 16:41:41 +10:00
Sumyjkl
fb28177ff1 items will stay put when loaded, items dug by the game will get more initial random velocity, game will no longer apply random velocity twice (?) 2022-07-23 16:10:52 +10:00
Sumyjkl
58d80e5e9c netherite items (except armour) will float in lava and not burn 2022-07-22 23:06:35 +10:00
Sumyjkl
eeace260fe don't disable physics if you've already disabled it 2022-07-22 22:45:22 +10:00
Sumyjkl
65fc5b6f28 droppers and dispensers actually shoot items out, items will merge with eachother even when floating 2022-07-22 22:38:36 +10:00
Sumyjkl
dc6fbeeafd items will go into sleep mode even if there's a block above as long as it's not a liquid 2022-07-22 16:55:42 +10:00
Sumyjkl
70aca4c3ca fix infinite bobbing 2022-07-22 16:19:50 +10:00
Sumyjkl
9daac0aff1 make items float in water sources 2022-07-22 15:34:58 +10:00
MysticTempest
677110e39f Disable the despawn timer catchup for items that were unloaded. 2022-07-03 04:28:43 -05:00
PrairieAstronomer
40a421ddd0 Hidden in the Depths Advancement 2022-07-01 12:41:01 -06:00
PrairieAstronomer
687bc04560 Who is Cutting Onions? Advancement 2022-07-01 12:39:10 -06:00
MysticTempest
b4c5805afe Make items flowing in water use acceleration for movement. 2022-06-03 05:46:27 -05:00
MysticTempest
5dde594c19 Item movement fixes:
This PR fixes items at flowing_water edges not falling down holes.
As well as fixing items not sliding on slippery nodes like ice.

And, allows for movement starting at the source block of a
flowing water node. While ensuring regular water_source blocks
do not bug out.
2022-06-02 09:44:04 +00:00
kabou
baf8e0b79c Update item entity for lodestone compass.
* Added another special case to the item entity registration for
  lodestone compasses, without this a dropped lodestone compass would
  turn into a regular compass on being dropped.
* Update the compass and lodestone compass frame number to be the
  stereotype frame.
2022-05-12 21:08:52 +02:00
GNU Hacker
f430aec0cd
item pickup sound gain more MC like 2022-03-13 14:58:01 +01:00
kabou
88f7a150c7 Add check for unknown nodes.
* Add check for unknown node in `handle_node_drops()` and return
  immediately if the dug node has no definition table.
2022-03-09 04:00:48 +01:00
Elias Fleckenstein
a4e73886d5
Rework XP API 2021-11-03 19:36:57 +01:00
Nils Dagsson Moskopp
256de2bc36 Log warning for non-serializable item entity fix 2021-09-15 18:10:40 +02:00
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
NO11
dc8436fdf9 Destroy objects near cactus faster (make it possible to throw items at a cactus) 2021-09-06 14:34:25 +00:00
AFCMS
cd33d406b2 fix many codestyle issues (functions, strings, modpaths) 2021-05-29 16:12:33 +02:00
AFCMS
3bedc81068 fix some code style issues in lightning 2021-05-28 00:07:06 +02:00
AFCMS
9e074af07f unify code style [1] 2021-05-25 12:52:25 +02:00
AFCMS
fddaacdeae [mcl_item_entity] fix warnings 2021-05-25 00:43:42 +02:00
Elias Fleckenstein
75d9450002 Make compasses point upwards when dropped as an item 2021-05-04 10:24:08 +02:00
Elias Fleckenstein
3b3d67a99c Make clocks work when dropped 2021-05-04 09:16:42 +02:00
jordan4ibanez
90fd65ac66 Fix locationless playing 2021-04-03 21:09:43 -04:00
jordan4ibanez
1b511936f5 Fix local name memory leak 2021-04-03 21:05:31 -04:00
jordan4ibanez
a807ee6372 Adjust the volume even more to perfectly match the gameplay 2021-04-03 20:55:46 -04:00
jordan4ibanez
0641f09915 Adjust volume of item collection sound 2021-04-03 20:53:34 -04:00
jordan4ibanez
c572db92aa Add sound buffer and different item collection sound 2021-04-03 20:39:08 -04:00
jordan4ibanez
844db8aa7b Revert to previous style of interpolated move_to with tweaks 2021-04-02 22:02:19 -04:00
jordan4ibanez
0840ad98a2 Adjust the item collection magnet even more 2021-04-02 21:57:38 -04:00
jordan4ibanez
1cbd3a998d Use manual move_to to account for move_to interpolation issues 2021-04-02 21:50:47 -04:00
jordan4ibanez
61e812e40a Add in manual interpolation into the item magnet 2021-04-02 21:40:04 -04:00
jordan4ibanez
18d7be4a4f More fixes to item collection on laggy servers 2021-04-03 00:42:20 -04:00
jordan4ibanez
1e3676c391 Remove debug info from item magnet 2021-04-02 05:38:53 +00:00