public static void Remove(GameObject pGameObject) { //get the singleton GhostManager pMan = privGetInstance(); Debug.Assert(pMan != null); // Compare functions only compares two Nodes pMan.pRefNode.pGameObj.SetName(pGameObject.GetName()); GhostNode pData = (GhostNode)pMan.baseFindNode(pMan.pRefNode); // release the resource pData.pGameObj = null; pMan.baseRemoveNode(pData); }
public static GameObject Find(GameObject.Name pGameObjectName) { //get the singleton GhostManager pMan = privGetInstance(); Debug.Assert(pMan != null); // Compare functions only compares two Nodes // Compare functions only compares two Nodes pMan.pRefNode.pGameObj.SetName(pGameObjectName); GhostNode pData = (GhostNode)pMan.baseFindNode(pMan.pRefNode); Debug.Assert(pData != null); return(pData.pGameObj); }