Skip to content

Commit

Permalink
Items should now respect group loot rules.
Browse files Browse the repository at this point in the history
  • Loading branch information
AnchyDev committed Oct 28, 2023
1 parent 230d31b commit 3f6b933
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/scripts/ToSInstanceScript.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -735,6 +735,8 @@ void ToSInstanceScript::PopulateRewardChest()
LootItem lootItem(*lootStoreItem);
lootItem.itemIndex = rewardChest->loot.items.size();
lootItem.itemid = rewardTemplate->itemEntry;
lootItem.follow_loot_rules = true;
lootItem.freeforall = false;

uint32 itemCount = urand(rewardTemplate->countMin, rewardTemplate->countMax);
if (rewardTemplate->curseScalar)
Expand Down Expand Up @@ -765,7 +767,7 @@ void ToSInstanceScript::PopulateRewardChest()
rewardChest->loot.generateMoneyLoot(minMoney, maxMoney);

rewardChest->SetLootGenerationTime();
rewardChest->SetLootState(GO_ACTIVATED);
rewardChest->SetLootState(GO_READY);
}

rewardBeam = instance->SummonGameObject(TOS_GOB_REWARD_BEAM, *tempPos, 0.0, 0.0, 0.0, 0.0, 0, true);
Expand Down

0 comments on commit 3f6b933

Please sign in to comment.