// --------------------------------------------------------------------

        private void CreateEntity()
        {
            NewEntityWindow window = new NewEntityWindow();

            if (window.ShowDialog() == DialogResult.OK)
            {
                SceneObject root = ParseNode(mCurrentModel.RootNode, false);
                EditorEntityUtils.Create(root, window.EntityName);
            }
        }
Ejemplo n.º 2
0
        // --------------------------------------------------------------------

        private void CreateEntity()
        {
            NewEntityWindow window = new NewEntityWindow();
            if (window.ShowDialog() == DialogResult.OK)
            {
                SceneObject root = ParseNode(mCurrentModel.RootNode, false, null);
                OnyxProjectAsset entity = ProjectManager.Instance.Content.GetEntityByName(window.EntityName);
                if (entity == null)
                    EditorEntityUtils.Create(root, window.EntityName);
                else
                    AssetLoader<Entity>.Save(new Entity(root), entity.Path);
            }
		}