Exemplo n.º 1
0
        public static void SetDynamicCondition(string objectName, string condition)
        {
            if (Instance.GetDynamic(objectName) != null)
            {
                Instance.SetDynamicData(objectName, condition);
            }
            else
            {
                Instance.AddDynamicData(objectName, condition);
            }

            //如果场景内有,就对其更新
            var dynamicObject = sceneDynamicObjects.Find(item => { return(item.key == objectName); });

            if (dynamicObject != null)
            {
                dynamicObject.UpdateCondition();
            }
        }