azurelib-fabric-26.3-4.0.11.jar
Curse Maven Snippet
What's new
v4.0.11
Additions
- Added separate first-person animators for items. Item renderers built with
useSeparateFirstPersonAnimator()give the first-person hands their own animator, so first person and third person can play different animations on the same item stack at the same time (for example, an aimed fire in first person while other players see a hip fire). - Added
AzCommand#sendForItemFirstPerson,AzCommand#sendForItemThirdPersonandAzCommand#sendForItem(Entity, ItemStack, AzItemAnimatorView)to play a command on only one view.
Fixes
- N/A
Changes
AzCommand#sendForItem(Entity, ItemStack)now plays on every animator the stack has. For renderers that don't use a separate first-person animator this is the same single animator as before.
Developer Notes
- Added
AzItemAnimatorView(DEFAULT,FIRST_PERSON). While an item renders, the view for its display context is the current view on the render thread, soAzAnimatorAccessorlookups on anItemStackduring rendering (render layers,AzProvider, custom pipeline code) return that view's animator. Outside of rendering they return theDEFAULTanimator. - Added
AzItemRendererConfig.Builder#setAnimatorViewProvider(Function<ItemDisplayContext, AzItemAnimatorView>)for custom context-to-view mappings.AzItemRendererConfig#animatorView(ItemDisplayContext)returns the view used for a context. AzIdentifiableItemStackAnimatorCachenow stores animators per view. The existingadd(ItemStack, AzItemAnimator)andgetOrNull(UUID)still useDEFAULT; new overloads take anAzItemAnimatorView, andforEach(UUID, AzItemAnimatorView, Consumer)runs on one view or, withnull, every view.ClientUtils#getCurrentAnimationControllerand#getCurrentAnimationTickread theDEFAULTanimator when called outside of rendering. To read the first-person animator, useAzIdentifiableItemStackAnimatorCache.getInstance().getOrNull(uuid, AzItemAnimatorView.FIRST_PERSON).AzItemStackDispatchCommandPackethas a new optional view field, which changes its network format. Clients and servers must run matching AzureLib versions.
All Relations
- All Relations
- Embedded Library
- Optional Dependency
- Required Dependency
- Tool
- Incompatible
- Include