Skip to content

Commit 39203f8

Browse files
committed
Add xskills fix
1 parent b4c6488 commit 39203f8

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

Systems/DeathContentManager.cs

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff 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);

0 commit comments

Comments
 (0)