File tree Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -154,6 +154,23 @@ private InventoryGeneric TakeContentFromPlayer(IServerPlayer byPlayer)
154154 continue ;
155155 }
156156
157+ // XSkills slots fix
158+ if ( invClassName . Equals ( GlobalConstants . backpackInvClassName ) &&
159+ byPlayer . InventoryManager . GetOwnInventory ( "xskillshotbar" ) != null )
160+ {
161+ int i = 0 ;
162+ var backpackInv = byPlayer . InventoryManager . GetOwnInventory ( invClassName ) ;
163+ foreach ( var slot in backpackInv )
164+ {
165+ if ( i > backpackInv . Count - 4 ) // Extra backpack slots
166+ {
167+ break ;
168+ }
169+ inv [ lastSlotId ++ ] . Itemstack = TakeSlotContent ( slot ) ;
170+ }
171+ continue ;
172+ }
173+
157174 foreach ( var slot in byPlayer . InventoryManager . GetOwnInventory ( invClassName ) )
158175 {
159176 inv [ lastSlotId ++ ] . Itemstack = TakeSlotContent ( slot ) ;
You can’t perform that action at this time.
0 commit comments