Ejemplo n.º 1
0
        override protected void AddRoot(IMyReplicable replicable)
        {
            System.Diagnostics.Debug.Assert(!replicable.HasToBeChild, "Cannot add children replicables to root!");

            m_roots.Add(replicable);

            BoundingBoxD aabb = replicable.GetAABB();

            m_proxies.Add(replicable, m_rootsAABB.AddProxy(ref aabb, replicable, 0));

            replicable.OnAABBChanged += OnRootMoved;
        }
Ejemplo n.º 2
0
        void OnRootMoved(IMyReplicable replicable)
        {
            BoundingBoxD aabb = replicable.GetAABB();

            m_rootsAABB.MoveProxy(m_proxies[replicable], ref aabb, Vector3D.One);
        }