mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-17 03:08:26 +00:00
[Items] Allow any bag type 51 to be used for Trader (#1392)
* Allow any bag type 51 to be used for Trader Most commonly this would allow the different color satchels to be used in Trader mode. PEQ database has 1 item (Yellow Trader's Satchel Token - 35037) marked as type 51, but otherwise only the proper bags are already set. Bonus of removing the hard-coded ID from source. * Updated Fixed where I missed it in a couple more spots too. * Update bonuses.cpp
This commit is contained in:
+4
-4
@@ -1266,7 +1266,7 @@ uint32 Client::FindTraderItemSerialNumber(int32 ItemID) {
|
||||
uint16 SlotID = 0;
|
||||
for (int i = EQ::invslot::GENERAL_BEGIN; i <= EQ::invslot::GENERAL_END; i++){
|
||||
item = this->GetInv().GetItem(i);
|
||||
if (item && item->GetItem()->ID == 17899){ //Traders Satchel
|
||||
if (item && item->GetItem()->BagType == EQ::item::BagTypeTradersSatchel){
|
||||
for (int x = EQ::invbag::SLOT_BEGIN; x <= EQ::invbag::SLOT_END; x++) {
|
||||
// we already have the parent bag and a contents iterator..why not just iterate the bag!??
|
||||
SlotID = EQ::InventoryProfile::CalcSlotId(i, x);
|
||||
@@ -1289,7 +1289,7 @@ EQ::ItemInstance* Client::FindTraderItemBySerialNumber(int32 SerialNumber){
|
||||
uint16 SlotID = 0;
|
||||
for (int i = EQ::invslot::GENERAL_BEGIN; i <= EQ::invslot::GENERAL_END; i++){
|
||||
item = this->GetInv().GetItem(i);
|
||||
if(item && item->GetItem()->ID == 17899){ //Traders Satchel
|
||||
if (item && item->GetItem()->BagType == EQ::item::BagTypeTradersSatchel){
|
||||
for (int x = EQ::invbag::SLOT_BEGIN; x <= EQ::invbag::SLOT_END; x++) {
|
||||
// we already have the parent bag and a contents iterator..why not just iterate the bag!??
|
||||
SlotID = EQ::InventoryProfile::CalcSlotId(i, x);
|
||||
@@ -1322,7 +1322,7 @@ GetItems_Struct* Client::GetTraderItems(){
|
||||
if (ndx >= 80)
|
||||
break;
|
||||
item = this->GetInv().GetItem(i);
|
||||
if(item && item->GetItem()->ID == 17899){ //Traders Satchel
|
||||
if (item && item->GetItem()->BagType == EQ::item::BagTypeTradersSatchel){
|
||||
for (int x = EQ::invbag::SLOT_BEGIN; x <= EQ::invbag::SLOT_END; x++) {
|
||||
if (ndx >= 80)
|
||||
break;
|
||||
@@ -1349,7 +1349,7 @@ uint16 Client::FindTraderItem(int32 SerialNumber, uint16 Quantity){
|
||||
uint16 SlotID = 0;
|
||||
for (int i = EQ::invslot::GENERAL_BEGIN; i <= EQ::invslot::GENERAL_END; i++) {
|
||||
item = this->GetInv().GetItem(i);
|
||||
if(item && item->GetItem()->ID == 17899){ //Traders Satchel
|
||||
if (item && item->GetItem()->BagType == EQ::item::BagTypeTradersSatchel){
|
||||
for (int x = EQ::invbag::SLOT_BEGIN; x <= EQ::invbag::SLOT_END; x++){
|
||||
SlotID = EQ::InventoryProfile::CalcSlotId(i, x);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user