Class GossipContainer
java.lang.Object
net.minecraft.world.entity.ai.gossip.GossipContainer
-
Nested Class Summary
Modifier and TypeClassDescription(package private) static class
(package private) static final record
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
private final Map<UUID,
GossipContainer.EntityGossips> private static final org.slf4j.Logger
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
add
(UUID p_26192_, GossipType p_26193_, int p_26194_) void
decay()
long
getCountForType
(GossipType p_148163_, DoublePredicate p_148164_) Map<UUID,
it.unimi.dsi.fastutil.objects.Object2IntMap<GossipType>> private GossipContainer.EntityGossips
getOrCreate
(UUID p_26190_) int
getReputation
(UUID p_26196_, Predicate<GossipType> p_26197_) private int
mergeValuesForAddition
(GossipType p_26168_, int p_26169_, int p_26170_) private static int
mergeValuesForTransfer
(int p_26159_, int p_26160_) void
remove
(UUID p_148169_, GossipType p_148170_) void
remove
(UUID p_148176_, GossipType p_148177_, int p_148178_) void
remove
(GossipType p_148161_) private Collection<GossipContainer.GossipEntry>
selectGossipsForTransfer
(RandomSource p_217760_, int p_217761_) <T> T
store
(com.mojang.serialization.DynamicOps<T> p_262915_) void
transferFrom
(GossipContainer p_217763_, RandomSource p_217764_, int p_217765_) private Stream<GossipContainer.GossipEntry>
unpack()
void
update
(com.mojang.serialization.Dynamic<?> p_26178_)
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
DISCARD_THRESHOLD
public static final int DISCARD_THRESHOLD- See Also:
-
gossips
-
-
Constructor Details
-
GossipContainer
public GossipContainer()
-
-
Method Details
-
getGossipEntries
-
decay
public void decay() -
unpack
-
selectGossipsForTransfer
private Collection<GossipContainer.GossipEntry> selectGossipsForTransfer(RandomSource p_217760_, int p_217761_) -
getOrCreate
-
transferFrom
-
getReputation
-
getCountForType
-
add
-
remove
-
remove
-
remove
-
store
public <T> T store(com.mojang.serialization.DynamicOps<T> p_262915_) -
update
public void update(com.mojang.serialization.Dynamic<?> p_26178_) -
mergeValuesForTransfer
private static int mergeValuesForTransfer(int p_26159_, int p_26160_) -
mergeValuesForAddition
-