标签:c style class blog code java
using UnityEngine; using UnityEngine; using UnityEditor; using System.Collections; public class AddChild : ScriptableObject { [MenuItem ("GameObject/+Add Child")] static void MenuAddChild() { Transform[] transforms = Selection.GetTransforms(SelectionMode.TopLevel | SelectionMode.OnlyUserModifiable); foreach(Transform transform in transforms) { GameObject newChild = new GameObject("_null"); newChild.transform.parent = transform; newChild.transform.localPosition = Vector3.zero; } } }
标签:c style class blog code java
原文地址:http://www.cnblogs.com/softimagewht/p/3765396.html