Exemplo n.º 1
0
    public Dictionary <int, Guide> guideMap = new Dictionary <int, Guide>();   //id, guide

    public void LoadHeros(string name)
    {
        byte[] bin     = DynamicFileControl.QueryFileContent(name);
        string content = StringHelper.ReadFromBytes(bin);

        LitJson.JSONNode json = LitJson.JSON.Parse(content);

        foreach (LitJson.JSONNode subNode in json.Childs)
        {
            DataGuide data = new DataGuide();
            data.Load(subNode);

            guidesGroup.Add(data);
        }

        CollectGuide();
    }