Class AttachmentInternals
java.lang.Object
net.neoforged.neoforge.attachment.AttachmentInternals
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static <H extends AttachmentHolder>
voidcopyAttachments(HolderLookup.Provider provider, H from, H to, Predicate<AttachmentType<?>> filter) Copy some attachments to another holder.static voidcopyChunkAttachmentsOnPromotion(HolderLookup.Provider provider, AttachmentHolder.AsField from, AttachmentHolder.AsField to) static voidcopyEntityAttachments(Entity from, Entity to, boolean isDeath) Do not call directly, useIEntityExtension.copyAttachmentsFrom(Entity, boolean).static voiddeserializeNonSyncedAttachments(AttachmentHolder holder, ValueInput input) Counterpart ofserializeNonSyncedAttachments(AttachmentHolder, ValueOutput); synced types in the input are ignored.static voidstatic voidonPlayerClone(PlayerEvent.Clone event) static voidserializeNonSyncedAttachments(AttachmentHolder holder, ValueOutput output) Serializes attachments that have no sync handler; used for client-local session data.
-
Constructor Details
-
AttachmentInternals
private AttachmentInternals()
-
-
Method Details
-
copyAttachments
private static <H extends AttachmentHolder> void copyAttachments(HolderLookup.Provider provider, H from, H to, Predicate<AttachmentType<?>> filter) Copy some attachments to another holder. -
copyChunkAttachmentsOnPromotion
public static void copyChunkAttachmentsOnPromotion(HolderLookup.Provider provider, AttachmentHolder.AsField from, AttachmentHolder.AsField to) -
copyEntityAttachments
Do not call directly, useIEntityExtension.copyAttachmentsFrom(Entity, boolean). -
onPlayerClone
-
onLivingConvert
-
serializeNonSyncedAttachments
Serializes attachments that have no sync handler; used for client-local session data. -
deserializeNonSyncedAttachments
Counterpart ofserializeNonSyncedAttachments(AttachmentHolder, ValueOutput); synced types in the input are ignored.
-