Package net.minecraft.item.map
Class MapState
java.lang.Object
net.minecraft.world.PersistentState
net.minecraft.item.map.MapState
public class MapState extends PersistentState
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classMapState.PlayerUpdateTracker -
Field Summary
Fields Modifier and Type Field Description private Map<String,MapBannerMarker>bannersbyte[]colorsRegistryKey<World>dimensionprivate static Loggerfield_25019private Map<String,MapFrameMarker>framesMap<String,MapIcon>iconsbooleanlockedbytescalebooleanshowIconsbooleanunlimitedTrackingList<MapState.PlayerUpdateTracker>updateTrackersprivate Map<PlayerEntity,MapState.PlayerUpdateTracker>updateTrackersByPlayerintxCenterintzCenter -
Constructor Summary
-
Method Summary
Modifier and Type Method Description voidaddBanner(WorldAccess world, BlockPos pos)static voidaddDecorationsTag(ItemStack stack, BlockPos pos, String id, MapIcon.Type type)private voidaddIcon(MapIcon.Type type, WorldAccess world, String key, double x, double z, double rotation, Text text)voidcalculateCenter(double x, double z, int scale)voidcopyFrom(MapState state)voidfromTag(CompoundTag tag)Packet<?>getPlayerMarkerPacket(ItemStack map, BlockView world, PlayerEntity pos)MapState.PlayerUpdateTrackergetPlayerSyncData(PlayerEntity player)voidinit(int x, int z, int scale, boolean showIcons, boolean unlimitedTracking, RegistryKey<World> dimension)voidmarkDirty(int x, int z)voidremoveBanner(BlockView world, int x, int z)voidremoveFrame(BlockPos pos, int id)CompoundTagtoTag(CompoundTag tag)voidupdate(PlayerEntity player, ItemStack stack)
-
Field Details
-
field_25019
-
xCenter
public int xCenter -
zCenter
public int zCenter -
dimension
-
showIcons
public boolean showIcons -
unlimitedTracking
public boolean unlimitedTracking -
scale
public byte scale -
colors
public byte[] colors -
locked
public boolean locked -
updateTrackers
-
updateTrackersByPlayer
-
banners
-
icons
-
frames
-
-
Constructor Details
-
MapState
-
-
Method Details
-
init
public void init(int x, int z, int scale, boolean showIcons, boolean unlimitedTracking, RegistryKey<World> dimension) -
calculateCenter
public void calculateCenter(double x, double z, int scale) -
fromTag
- Specified by:
fromTagin classPersistentState
-
toTag
- Specified by:
toTagin classPersistentState
-
copyFrom
-
update
-
addDecorationsTag
-
addIcon
private void addIcon(MapIcon.Type type, @Nullable WorldAccess world, String key, double x, double z, double rotation, @Nullable Text text) -
getPlayerMarkerPacket
-
markDirty
public void markDirty(int x, int z) -
getPlayerSyncData
-
addBanner
-
removeBanner
-
removeFrame
-