mirror of
https://github.com/EQEmu/Server.git
synced 2026-03-12 12:12:25 +00:00
Fix item reward message
This commit is contained in:
parent
9f1519cd94
commit
9118d13f2f
@ -974,8 +974,6 @@ void ClientTaskState::RewardTask(Client *c, const TaskInformation *ti, ClientTas
|
|||||||
|
|
||||||
// TODO: this function should sometimes use QuestReward_Struct and CashReward_Struct
|
// TODO: this function should sometimes use QuestReward_Struct and CashReward_Struct
|
||||||
// assumption is they use QuestReward_Struct when there is more than 1 thing getting rewarded
|
// assumption is they use QuestReward_Struct when there is more than 1 thing getting rewarded
|
||||||
const EQ::ItemData *item_data;
|
|
||||||
std::vector<int> reward_list;
|
|
||||||
if (ti->reward_method != METHODQUEST) {
|
if (ti->reward_method != METHODQUEST) {
|
||||||
for (const auto &i: Strings::Split(ti->reward_id_list, "|")) {
|
for (const auto &i: Strings::Split(ti->reward_id_list, "|")) {
|
||||||
// handle charges
|
// handle charges
|
||||||
@ -996,10 +994,8 @@ void ClientTaskState::RewardTask(Client *c, const TaskInformation *ti, ClientTas
|
|||||||
if (!stacked) {
|
if (!stacked) {
|
||||||
int16_t slot = c->GetInv().FindFreeSlot(inst->IsClassBag(), true, inst->GetItem()->Size);
|
int16_t slot = c->GetInv().FindFreeSlot(inst->IsClassBag(), true, inst->GetItem()->Size);
|
||||||
c->SummonItem(item_id, charges, 0, 0, 0, 0, 0, 0, false, slot);
|
c->SummonItem(item_id, charges, 0, 0, 0, 0, 0, 0, false, slot);
|
||||||
if (item_data) {
|
|
||||||
c->MessageString(Chat::Yellow, YOU_HAVE_BEEN_GIVEN, inst->GetItem()->Name);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
c->MessageString(Chat::Yellow, YOU_HAVE_BEEN_GIVEN, inst->GetItem()->Name);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user