StonehearthEditor.EncounterNodeData.PostLoadFixup C# (CSharp) Method

PostLoadFixup() public method

public PostLoadFixup ( ) : void
return void
        public override void PostLoadFixup()
        {
            string selector = null;
            string monsterTuningSelector = null;
            switch (mEncounterType)
            {
                case "create_camp":
                    selector = "create_camp_info.*.loot_drops";
                    break;
                case "city_raid":
                    selector = "city_raid_info.missions.*.members.*.loot_drops";
                    monsterTuningSelector = "city_raid_info.missions.*.members.*";
                    break;
                case "donation_dialog":
                    selector = "donation_dialog_info.loot_table";
                    break;
                case "donation":
                    selector = "donation_info.loot_table";
                    break;
                case "create_mission":
                    selector = "create_mission_info.mission.members.*.loot_drops";
                    monsterTuningSelector = "create_mission_info.mission.members.*";
                    break;
            }

            if (selector != null)
            {
                FixupLoot(selector);
            }

            if (monsterTuningSelector != null)
            {
                if (NodeFile.Json != null)
                {
                    foreach (JToken token in NodeFile.Json.SelectTokens(monsterTuningSelector))
                    {
                        if (token["tuning"] == null)
                        {
                            Console.WriteLine(NodeFile.Path + " does not have monster tuning!");
                        }
                    }
                }
            }
        }