Exemple #1
0
 public void Clear()
 {
     if (IsReadonly)
     {
         throw new Exception("Someone was either stuck processing or didn't properly dispose of Enumerator for AABBTree.");
     }
     DynamicNodeLookup.Clear();
     StaticNodeLookup.Clear();
     Root = null;
 }
Exemple #2
0
 public void Rebuild()
 {
     if (IsReadonly)
     {
         throw new Exception("Someone was either stuck processing or didn't properly dispose of Enumerator for AABBTree.");
     }
     DynamicNodeLookup.Clear();
     StaticNodeLookup.Clear();
     base.ReinitializeTreeFromRootItem();
 }
Exemple #3
0
    public bool Remove(IStaticObject MyItem)
    {
        if (IsReadonly)
        {
            throw new Exception("Someone was either stuck processing or didn't properly dispose of Enumerator for AABBTree.");
        }
        IAABBNode NodeData;

        if (StaticNodeLookup.TryGetValue((Object)MyItem, out NodeData))
        {
            base.RemoveNode(NodeData);
            StaticNodeLookup.Remove((Object)MyItem);
            return(true);
        }
        else
        {
            return(false);
        }
    }