Commit Graph

12 Commits

Author SHA1 Message Date
Jake Potrebic
e09a44e169
fix some compile issues 2023-06-07 14:46:56 -07:00
Nassim Jahnke
197786ead0
More more work 2023-06-07 20:31:32 +02:00
Owen
841da90501
Paper Plugins (#8108) 2023-02-19 08:57:10 -06:00
Jake Potrebic
afe633df08
convert API/server tests to mockito (#8848)
* convert API tests to mockito

* convert server tests to mockito

* add co-author
2023-02-15 13:27:40 -08:00
brickmonster
f2f9e8cc4d
Remove patch that was made obsolete by vanilla (#8847) 2023-02-13 18:52:27 +01:00
Nassim Jahnke
0edb5458e5
Patching patches 2022-12-07 19:32:25 +01:00
Nassim Jahnke
fd58a696cb
API patches 2022-12-07 17:46:46 +01:00
Jake Potrebic
e22dacf4d2
update yarn param mappings (#8563) 2022-11-12 12:57:41 -08:00
Spottedleaf
25cd3eee99 Add dirty flag to chunk tick lists
For whatever reason, vanilla does not mark the chunk as
dirty when changing its tick lists.

We also have it return dirty if the time since the last
save has changed, since it would affect the tick offsets
in the ticklist.
2022-10-24 20:51:48 -07:00
Spottedleaf
f7da209586 Fix inconsistent isChunkLoaded calls
When we update the chunk state to border, it should be
the case that isChunkLoaded returns true and that
getChunkIfLoadedImmediately returns a non-null value.
Now add the chunk to the loaded map before making any
callbacks after updating to border state.
2022-10-18 08:11:23 -07:00
Nassim Jahnke
928bcc8d3a
Updated Upstream (Bukkit/CraftBukkit) (#8430)
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
09943450 Update SnakeYAML version
5515734f SPIGOT-7162: Incorrect description for Entity#getVehicle javadoc
6f82b381 PR-788: Add getHand() to all relevant events

CraftBukkit Changes:
aaf484f6f SPIGOT-7163: CraftMerchantRecipe doesn't copy demand and specialPrice from BukkitMerchantRecipe
5329dd6fd PR-1107: Add getHand() to all relevant events
93061706e SPIGOT-7045: Ocelots never spawn with babies with spawn reason OCELOT_BABY
2022-10-02 09:56:36 +02:00
Spottedleaf
01a13871de
Rewrite chunk system (#8177)
Patch documentation to come

Issues with the old system that are fixed now:
- World generation does not scale with cpu cores effectively.
- Relies on the main thread for scheduling and maintaining chunk state, dropping chunk load/generate rates at lower tps.
- Unreliable prioritisation of chunk gen/load calls that block the main thread.
- Shutdown logic is utterly unreliable, as it has to wait for all chunks to unload - is it guaranteed that the chunk system is in a state on shutdown that it can reliably do this? Watchdog shutdown also typically failed due to thread checks, which is now resolved.
- Saving of data is not unified (i.e can save chunk data without saving entity data, poses problems for desync if shutdown is really abnormal.
- Entities are not loaded with chunks. This caused quite a bit of headache for Chunk#getEntities API, but now the new chunk system loads entities with chunks so that they are ready whenever the chunk loads in. Effectively brings the behavior back to 1.16 era, but still storing entities in their own separate regionfiles.

The above list is not complete. The patch documentation will complete it.

New chunk system hard relies on starlight and dataconverter, and most importantly the new concurrent utilities in ConcurrentUtil.

Some of the old async chunk i/o interface (i.e the old file io thread reroutes _some_ calls to the new file io thread) is kept for plugin compat reasons. It will be removed in the next major version of minecraft.

The old legacy chunk system patches have been moved to the removed folder in case we need them again.
2022-09-26 01:02:51 -07:00