1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2025-01-10 01:10:30 +00:00
CC-Tweaked/projects
Jonathan Coates bb97c465d9
Fix computers/turtles not being dropped on explosion
Computer drops are currently[^1] implemented via a dynamic drop. To
support this, we need to inject the dynamic drop into the loot
parameters.

We currently do this by implementing our own drop logic in
playerWillDestroy[^2], manually creating the loot params and adding our
additional drop. However, if the item is dropped via some other method
(such as via explosions), we'll go through vanilla's drop logic and so
never add the dynamic drop!

The correct way to do this is to override getDrops to add the dynamic
drop instead. I don't know why we didn't always do this -- the code in
question was first written for MC 1.14[^3], when things were very
different.

[^1]: This is no longer the case on 1.21, where we can just copy
      capabilities.

[^2]: We need to override vanilla's drop behaviour to ensure items are
      dropped in creative mode.

[^3]: See 594bc4203c. Which probably means
      the bug has been around for 5 years :/.
2024-08-14 21:12:30 +01:00
..
common Fix computers/turtles not being dropped on explosion 2024-08-14 21:12:30 +01:00
common-api Allow registering more generic detail providers 2024-08-11 11:51:40 +01:00
core Fix return type of Vector.dot 2024-08-11 14:11:14 +01:00
core-api Move API factories to the common package 2024-07-29 19:46:25 +01:00
fabric Register modems as attached to their adjacent block 2024-07-26 18:28:13 +01:00
fabric-api Rewrite turtle upgrade modeller registration API 2024-01-16 23:00:49 +00:00
forge Register modems as attached to their adjacent block 2024-07-26 18:28:13 +01:00
forge-api Rewrite turtle upgrade modeller registration API 2024-01-16 23:00:49 +00:00
lints Fix NPE when rendering turtle's label 2024-04-06 08:46:19 +01:00
standalone Small bits of cleanup 2024-06-26 18:07:57 +01:00
web Publish docs via an artifact instead 2024-06-19 09:57:56 +01:00
ARCHITECTURE.md Add a standalone CC:T UI 2023-10-28 17:58:11 +01:00