Exemple #1
0
        private void Create(JsonData jsonNode)
        {
            ComponentDeserializer.FromJson(jsonNode, out name, out path, out layer, out tag, out localPosition, out localRotation, out localScale);
            if (Application.isPlaying)
            {
                tag = tag == TagUtility.EditorOnly ? TagUtility.Untagged : tag;
            }

            ComponentDeserializer.ComponentsFromJson(jsonNode, (comJson) =>
            {
                components.Add(new RobotComponentDataModel(comJson));
            });

            ComponentDeserializer.ChildrenFromJson(jsonNode, (childJson) =>
            {
                children.Add(new RobotGameObjectDataModel(childJson));
            });
        }