Exemple #1
0
        public bool ReleaseProp(bool dispatchPlacementEffect)
        {
            CheckPropStillExists();

            if (stillExists == false)
            {
                return(false);
            }
            else
            {
                if (Singleton <PropManager> .instance.m_props.m_buffer[(int)((UIntPtr)propPlacementInfo.propID)].m_flags != 0)
                {
                    PropManager instance = Singleton <PropManager> .instance;
                    instance.ReleaseProp(propPlacementInfo.propID);
                    if (dispatchPlacementEffect)
                    {
                        PropLineTool.DispatchPlacementEffect(propPlacementInfo.position, true);
                    }

                    return(true);
                }

                return(false);
            }
        }
Exemple #2
0
        public bool ReleaseTree(bool dispatchPlacementEffect)
        {
            CheckTreeStillExists();

            if (stillExists == false)
            {
                return(false);
            }
            else
            {
                TreeManager instance = Singleton <TreeManager> .instance;
                instance.ReleaseTree(treePlacementInfo.treeID);
                if (dispatchPlacementEffect)
                {
                    PropLineTool.DispatchPlacementEffect(treePlacementInfo.position, true);
                }

                return(true);
            }
        }