Class ThreadedAnvilChunkStorage.EntityTracker

java.lang.Object
net.minecraft.server.world.ThreadedAnvilChunkStorage.EntityTracker
Enclosing class:
ThreadedAnvilChunkStorage

private class ThreadedAnvilChunkStorage.EntityTracker extends Object
An entity tracker governs which players' clients can see an entity. Each tracker corresponds to one entity in a server world and is mapped from the entity's network ID.
See Also:
Mappings:
Namespace Name
official abe$b
intermediary net/minecraft/class_3898$class_3208
named net/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker
  • Field Details

    • entry

      final EntityTrackerEntry entry
      Mappings:
      Namespace Name Mixin selector
      official b Labe$b;b:Labq;
      intermediary field_18246 Lnet/minecraft/class_3898$class_3208;field_18246:Lnet/minecraft/class_3231;
      named entry Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;entry:Lnet/minecraft/server/network/EntityTrackerEntry;
    • entity

      final Entity entity
      Mappings:
      Namespace Name Mixin selector
      official c Labe$b;c:Latf;
      intermediary field_18247 Lnet/minecraft/class_3898$class_3208;field_18247:Lnet/minecraft/class_1297;
      named entity Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;entity:Lnet/minecraft/entity/Entity;
    • maxDistance

      private final int maxDistance
      Mappings:
      Namespace Name Mixin selector
      official d Labe$b;d:I
      intermediary field_18248 Lnet/minecraft/class_3898$class_3208;field_18248:I
      named maxDistance Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;maxDistance:I
    • trackedSection

      ChunkSectionPos trackedSection
      The chunk section position of the tracked entity, may be outdated as an entity ticks. This is used by tickEntityMovement() to bypass unnecessary status updates before calling updateTrackedStatus().
      Mappings:
      Namespace Name Mixin selector
      official e Labe$b;e:Lgz;
      intermediary field_18249 Lnet/minecraft/class_3898$class_3208;field_18249:Lnet/minecraft/class_4076;
      named trackedSection Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;trackedSection:Lnet/minecraft/util/math/ChunkSectionPos;
    • listeners

      private final Set<EntityTrackingListener> listeners
      Mappings:
      Namespace Name Mixin selector
      official f Labe$b;f:Ljava/util/Set;
      intermediary field_18250 Lnet/minecraft/class_3898$class_3208;field_18250:Ljava/util/Set;
      named listeners Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;listeners:Ljava/util/Set;
  • Constructor Details

    • EntityTracker

      public EntityTracker(Entity entity, int maxDistance, int tickInterval, boolean alwaysUpdateVelocity)
      Mappings:
      Namespace Name Mixin selector
      official <init> Labe$b;<init>(Labe;Latf;IIZ)V
      intermediary <init> Lnet/minecraft/class_3898$class_3208;<init>(Lnet/minecraft/class_3898;Lnet/minecraft/class_1297;IIZ)V
      named <init> Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;<init>(Lnet/minecraft/server/world/ThreadedAnvilChunkStorage;Lnet/minecraft/entity/Entity;IIZ)V
  • Method Details

    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
      Mappings:
      Namespace Name Mixin selector
      official equals Labe$b;equals(Ljava/lang/Object;)Z
      intermediary equals Lnet/minecraft/class_3898$class_3208;equals(Ljava/lang/Object;)Z
      named equals Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;equals(Ljava/lang/Object;)Z
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • sendToOtherNearbyPlayers

      public void sendToOtherNearbyPlayers(Packet<?> packet)
      Mappings:
      Namespace Name Mixin selector
      official a Labe$b;a(Lpk;)V
      intermediary method_18730 Lnet/minecraft/class_3898$class_3208;method_18730(Lnet/minecraft/class_2596;)V
      named sendToOtherNearbyPlayers Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;sendToOtherNearbyPlayers(Lnet/minecraft/network/Packet;)V
    • sendToNearbyPlayers

      public void sendToNearbyPlayers(Packet<?> packet)
      Mappings:
      Namespace Name Mixin selector
      official b Labe$b;b(Lpk;)V
      intermediary method_18734 Lnet/minecraft/class_3898$class_3208;method_18734(Lnet/minecraft/class_2596;)V
      named sendToNearbyPlayers Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;sendToNearbyPlayers(Lnet/minecraft/network/Packet;)V
    • stopTracking

      public void stopTracking()
      Mappings:
      Namespace Name Mixin selector
      official a Labe$b;a()V
      intermediary method_18728 Lnet/minecraft/class_3898$class_3208;method_18728()V
      named stopTracking Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;stopTracking()V
    • stopTracking

      public void stopTracking(ServerPlayerEntity player)
      Mappings:
      Namespace Name Mixin selector
      official a Labe$b;a(Labs;)V
      intermediary method_18733 Lnet/minecraft/class_3898$class_3208;method_18733(Lnet/minecraft/class_3222;)V
      named stopTracking Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;stopTracking(Lnet/minecraft/server/network/ServerPlayerEntity;)V
    • updateTrackedStatus

      public void updateTrackedStatus(ServerPlayerEntity player)
      Updates the tracked status of this tracker's entity for the player.

      If this tracker should be listened by the player, the player's tracking listener is added if it is not in the listeners; if this tracker should not be listened by the player, the player's tracking listener is removed if it is in the listeners.

      Mappings:
      Namespace Name Mixin selector
      official b Labe$b;b(Labs;)V
      intermediary method_18736 Lnet/minecraft/class_3898$class_3208;method_18736(Lnet/minecraft/class_3222;)V
      named updateTrackedStatus Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;updateTrackedStatus(Lnet/minecraft/server/network/ServerPlayerEntity;)V
    • adjustTrackingDistance

      private int adjustTrackingDistance(int initialDistance)
      Mappings:
      Namespace Name Mixin selector
      official a Labe$b;a(I)I
      intermediary method_27906 Lnet/minecraft/class_3898$class_3208;method_27906(I)I
      named adjustTrackingDistance Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;adjustTrackingDistance(I)I
    • getMaxTrackDistance

      private int getMaxTrackDistance()
      Mappings:
      Namespace Name Mixin selector
      official b Labe$b;b()I
      intermediary method_22844 Lnet/minecraft/class_3898$class_3208;method_22844()I
      named getMaxTrackDistance Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;getMaxTrackDistance()I
    • updateTrackedStatus

      public void updateTrackedStatus(List<ServerPlayerEntity> players)
      Updates the tracked status of this tracker's entity for the given players.
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official a Labe$b;a(Ljava/util/List;)V
      intermediary method_18729 Lnet/minecraft/class_3898$class_3208;method_18729(Ljava/util/List;)V
      named updateTrackedStatus Lnet/minecraft/server/world/ThreadedAnvilChunkStorage$EntityTracker;updateTrackedStatus(Ljava/util/List;)V