mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-12 05:21:29 +00:00
Merge pull request #235 from addtheice/guild_mgr_patch
Fixed bug with loading failing on Guild bank areas
This commit is contained in:
commit
7ddaabee30
@ -686,19 +686,26 @@ bool GuildBankManager::Load(uint32 guildID)
|
|||||||
else
|
else
|
||||||
whoFor[0] = '\0';
|
whoFor[0] = '\0';
|
||||||
|
|
||||||
if(slot < 0 ||
|
if(slot < 0)
|
||||||
((area != GuildBankMainArea || slot >= GUILD_BANK_MAIN_AREA_SIZE) ||
|
|
||||||
(area == GuildBankMainArea || slot >= GUILD_BANK_DEPOSIT_AREA_SIZE)))
|
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
bank->Items.MainArea[slot].ItemID = itemID;
|
GuildBankItem *itemSection = nullptr;
|
||||||
bank->Items.MainArea[slot].Quantity = qty;
|
|
||||||
|
|
||||||
strn0cpy(bank->Items.MainArea[slot].Donator, donator, sizeof(donator));
|
if (area == GuildBankMainArea && slot < GUILD_BANK_MAIN_AREA_SIZE)
|
||||||
|
itemSection = bank->Items.MainArea;
|
||||||
|
else if (area != GuildBankMainArea && slot < GUILD_BANK_DEPOSIT_AREA_SIZE)
|
||||||
|
itemSection = bank->Items.DepositArea;
|
||||||
|
else
|
||||||
|
continue;
|
||||||
|
|
||||||
bank->Items.MainArea[slot].Permissions = permissions;
|
itemSection[slot].ItemID = itemID;
|
||||||
|
itemSection[slot].Quantity = qty;
|
||||||
|
|
||||||
strn0cpy(bank->Items.MainArea[slot].WhoFor, whoFor, sizeof(whoFor));
|
strn0cpy(itemSection[slot].Donator, donator, sizeof(donator));
|
||||||
|
|
||||||
|
itemSection[slot].Permissions = permissions;
|
||||||
|
|
||||||
|
strn0cpy(itemSection[slot].WhoFor, whoFor, sizeof(whoFor));
|
||||||
}
|
}
|
||||||
|
|
||||||
Banks.push_back(bank);
|
Banks.push_back(bank);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user