fix bug in stack count

This commit is contained in:
Chomp 2021-09-11 14:07:34 +01:00
parent a46ae82c3e
commit bb40918722

View File

@ -119,9 +119,9 @@ namespace QuestValidator
CheckValuesMatch(questSuccessRewardItem.value, relatedLiveRewardItem.value, "mismatch for success item reward value", questSuccessRewardItem.id);
// Check item stack count
if (questSuccessRewardItem.items[0] != null && questSuccessRewardItem.items[0].upd != null)
if (questSuccessRewardItem.items[0]?.upd != null && relatedLiveRewardItem.items[0]?.upd != null)
{
CheckValuesMatch(questSuccessRewardItem.items[0].upd.StackObjectsCount, questSuccessRewardItem.items[0].upd.StackObjectsCount, "mismatch for success item StackObjectsCount", questSuccessRewardItem.items[0]._id);
CheckValuesMatch(questSuccessRewardItem.items[0].upd.StackObjectsCount, relatedLiveRewardItem.items[0].upd.StackObjectsCount, "mismatch for success item StackObjectsCount", questSuccessRewardItem.items[0]._id);
}
// check sub items match