Automatically stacks all loot that does not fit in bags. For example if item has max stack size of 20 and you loot 25 in total from nearby NPCs, then a stack of 20 and a stack of 5 are created.
Fills mails with all items it can (max 12 item stacks per mail)
No longer spams the player with "Your items have been mailed to you", but does still spam chat for now.
Also implements randomPropertyId generation which seemed to be missing from the mail method
Tests performed: (Does it build, tested in-game, etc)
Builds, works in game.
Tested with npc 6228 that drops handcuffs with random property
Tested with npc 113 that drops normal loot
Known issues and TODO list:
Was first thinking about implementing randomPropertyId stuff in the base TC. However, it seems that RewardQuest, disenchang only use the same mail method. I assume disenchant does not return randomprop items and the following returns nothing so its probably not needed unless someone makes custom quests that use items with random properties. Not sure how DF quests work though.
SELECT * FROM quest_template b WHERE
b.RewardChoiceItemID1 IN(
SELECT entry FROM item_template a WHERE a.RandomProperty <> 0)
OR
b.RewardChoiceItemID2 IN(
SELECT entry FROM item_template a WHERE a.RandomProperty <> 0)
OR
b.RewardChoiceItemID3 IN(
SELECT entry FROM item_template a WHERE a.RandomProperty <> 0)
OR
b.RewardChoiceItemID4 IN(
SELECT entry FROM item_template a WHERE a.RandomProperty <> 0)
OR
b.RewardChoiceItemID5 IN(
SELECT entry FROM item_template a WHERE a.RandomProperty <> 0)
OR
b.RewardChoiceItemID6 IN(
SELECT entry FROM item_template a WHERE a.RandomProperty <> 0)
Changes proposed:
Target branch(es): 335/6x 335
Issues addressed: Fixes https://github.com/TrinityCore/TrinityCoreCustomChanges/issues/76
Tests performed: (Does it build, tested in-game, etc) Builds, works in game. Tested with npc 6228 that drops handcuffs with random property Tested with npc 113 that drops normal loot
Known issues and TODO list: