13
0
geforkt von Mirrors/Paper

Configurable item frame map cursor update interval

Dieser Commit ist enthalten in:
Warrior 2021-08-13 01:14:38 +02:00
Ursprung 8a3f9f7eb6
Commit c754319985

Datei anzeigen

@ -69,7 +69,7 @@
ItemStack itemstack = entityitemframe.getItem();
- if (itemstack.getItem() instanceof MapItem) {
+ if (this.tickCount % 10 == 0 && itemstack.getItem() instanceof MapItem) { // CraftBukkit - Moved this.tickCounter % 10 logic here so item frames do not enter the other blocks
+ if (this.level.paperConfig().maps.itemFrameCursorUpdateInterval > 0 && this.tickCount % this.level.paperConfig().maps.itemFrameCursorUpdateInterval == 0 && itemstack.getItem() instanceof MapItem) { // CraftBukkit - Moved this.tickCounter % 10 logic here so item frames do not enter the other blocks // Paper - Make item frame map cursor update interval configurable
MapId mapid = (MapId) itemstack.get(DataComponents.MAP_ID);
MapItemSavedData worldmap = MapItem.getSavedData(mapid, this.level);