@@ -44,7 +44,13 @@ protected void rollbackArmorTransaction(
4444 switch (transaction ) {
4545 case MoveTransaction <?> moveTransaction -> {
4646 if (moveTransaction .getMoveType () == MoveType .MOVE_TO_SELF ) {
47- rollbackArmorTransaction (player , armorContainer , moveTransaction .getAddTransaction (), refundedKeys , commandBuffer );
47+ rollbackArmorTransaction (
48+ player ,
49+ armorContainer ,
50+ moveTransaction .getAddTransaction (),
51+ refundedKeys ,
52+ commandBuffer
53+ );
4854 }
4955 }
5056 case ListTransaction <?> listTransaction -> {
@@ -78,7 +84,7 @@ protected void rollbackArmorTransaction(
7884 return ;
7985 }
8086 var playerRefComponent = playerRef .getStore ()
81- .getComponent (playerRef , PlayerRef .getComponentType ());
87+ .getComponent (playerRef , PlayerRef .getComponentType ());
8288 if (playerRefComponent == null ) {
8389 return ;
8490 }
@@ -90,7 +96,7 @@ protected void rollbackArmorTransaction(
9096 var classId = restrictionCache .getClassId (playerUuid ).orElse ("Unknown" );
9197
9298 NotificationsUtil .sendItemClassRestrictionNotification (
93- playerRefComponent ,
99+ playerRefComponent ,
94100 after ,
95101 classId
96102 );
@@ -102,9 +108,9 @@ protected void rollbackArmorTransaction(
102108 var key = "armorSlot:" + slotTransaction .getSlot ();
103109 if (refundedKeys .add (key )) {
104110 var everythingInventoryComponent = InventoryComponent .getCombined (
105- commandBuffer ,
106- playerRef ,
107- InventoryComponent .EVERYTHING
111+ commandBuffer ,
112+ playerRef ,
113+ InventoryComponent .EVERYTHING
108114 );
109115 giveOrDrop (player , after , everythingInventoryComponent );
110116
@@ -125,7 +131,7 @@ public void validateArmorOnReady(@Nonnull Player player) {
125131 return ;
126132 }
127133 var playerRefComponent = playerRef .getStore ()
128- .getComponent (playerRef , PlayerRef .getComponentType ());
134+ .getComponent (playerRef , PlayerRef .getComponentType ());
129135 if (playerRefComponent == null ) {
130136 return ;
131137 }
@@ -167,16 +173,16 @@ public void validateArmorOnReady(@Nonnull Player player) {
167173 var classId = restrictionCache .getClassId (playerUuid ).orElse ("Unknown" );
168174
169175 NotificationsUtil .sendItemClassRestrictionNotification (
170- playerRefComponent ,
176+ playerRefComponent ,
171177 stack ,
172178 classId
173179 );
174180
175181 armor .setItemStackForSlot (slot , null , true );
176182 var everythingInventoryComponent = InventoryComponent .getCombined (
177- playerRef .getStore (),
178- playerRef ,
179- InventoryComponent .EVERYTHING
183+ playerRef .getStore (),
184+ playerRef ,
185+ InventoryComponent .EVERYTHING
180186 );
181187 giveOrDrop (player , stack , everythingInventoryComponent );
182188 }
0 commit comments