private void OnProductItemClickByShowCAD(BumModel bumModel)
 {
     if (this.currentLoadObject == null)
     {
         BumResourceManager.loadResource(bumModel.modelUri, null, null, BumResourceType.eBumResourceType_assetBundle, BumLoadingType.eBumLoadingType_www, BumResourcePoolType.ProductObject, bumModel.PlacementSurfaces, OnLoad);
     }
 }
Exemplo n.º 2
0
    public BumModel getModel(string id)
    {
        BumModel temp = null;

        modelCollection.TryGetValue(id, out temp);

        return(temp);
    }
Exemplo n.º 3
0
 private void OnItemClick(BumModel obj)
 {
     Debug.Log("OnItemClick");
     if (OnModelClick != null)
     {
         OnModelClick(obj);
     }
 }
Exemplo n.º 4
0
    public IEnumerator init()
    {
        string modelUrl = "http://pboypz1tn.bkt.clouddn.com/was/table/projectTable.json";

        BumResourceManager.loadResource(modelUrl, (object data) =>
        {
            string json     = (string)data;
            object jsonData = BumJsonTool.FromJson(json);
            if (jsonData == null)
            {
                return;
            }
            List <object> listData = jsonData as List <object>;
            for (int i = 0; i < listData.Count; i++)
            {
                BumModel model = new BumModel();
                model.Deserializable(listData[i] as Dictionary <string, object>);
                modelCollection.Add(model.uuid, model);
            }

            loadingOver = true;
        }, null, BumResourceType.eBumResourceType_json);
        yield return(null);
    }