本文整理汇总了C++中CGroupMap::delCtrl方法的典型用法代码示例。如果您正苦于以下问题:C++ CGroupMap::delCtrl方法的具体用法?C++ CGroupMap::delCtrl怎么用?C++ CGroupMap::delCtrl使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CGroupMap
的用法示例。
在下文中一共展示了CGroupMap::delCtrl方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: onRemove
//*********************************************************************************************************
void CInstanceMapDeco::onRemove(CGroupMap &owner)
{
//H_AUTO(R2_CInstanceMapDeco_onRemove)
nlassert(_Instance);
nlassert(_Main);
nlassert(_Over);
nlassert(_OverInvalid);
owner.delCtrl(_Main);
_Main = NULL;
owner.delCtrl(_Over);
_Over = NULL;
owner.delCtrl(_OverInvalid);
_OverInvalid = NULL;
if (_Orient)
{
owner.delCtrl(_Orient);
_Orient = NULL;
}
if (_GlowStar[0])
{
_GlowStar[0]->getParent()->delCtrl(_GlowStar[0]);
_GlowStar[0] = NULL;
_GlowStar[1]->getParent()->delCtrl(_GlowStar[1]);
_GlowStar[1] = NULL;
}
_AddedToMap = false;
_Instance = NULL;
}
示例2: setWorldMapNumEdges
//*********************************************************
void CDisplayerVisualActivitySequence::setWorldMapNumEdges(uint count)
{
//H_AUTO(R2_CDisplayerVisualActivitySequence_setWorldMapNumEdges)
// TODO nico : try to factor with CPrimRender::setWorldMapNumEdges
nlassert(_AddedToWorldMap);
CGroupMap *gm = CTool::getWorldMap();
nlassert(gm);
if (count < _WorldMapEdges.size())
{
for(uint k = count; k < _WorldMapEdges.size(); ++k)
{
gm->delCtrl(_WorldMapEdges[k]);
}
}
else
{
uint left = count - (uint)_WorldMapEdges.size();
while (left --)
{
CCtrlQuad *cq = new CCtrlQuad;
cq->setModulateGlobalColor(false);
cq->setActive(true);
gm->addCtrl(cq);
cq->setParent(gm);
cq->setRenderLayer(1);
_WorldMapEdges.push_back(cq);
}
}
_WorldMapEdges.resize(count);
for(uint k = 0; k < count; ++k)
{
_WorldMapEdges[k]->setTexture(CV_FootStepMapTexture.get());
}
}
示例3: onRemove
// *********************************************************
void CPrimRender::onRemove(CGroupMap &owner)
{
//H_AUTO(R2_CPrimRender_onRemove)
nlassert(_AddedToWorldMap);
setWorldMapNumVertices(0);
setWorldMapNumEdges(0);
if (_WorldMapPoly)
{
owner.delCtrl(_WorldMapPoly);
_WorldMapPoly = NULL;
}
_AddedToWorldMap = false;
}
示例4: setWorldMapNumEdges
// *********************************************************
void CPrimRender::setWorldMapNumEdges(uint count)
{
//H_AUTO(R2_CPrimRender_setWorldMapNumEdges)
nlassert(_AddedToWorldMap);
CGroupMap *gm = CTool::getWorldMap();
nlassert(gm);
if (count < _WorldMapEdges.size())
{
for(uint k = count; k < _WorldMapEdges.size(); ++k)
{
gm->delCtrl(_WorldMapEdges[k]);
}
}
else
{
uint left = count - (uint)_WorldMapEdges.size();
while (left --)
{
CCtrlQuad *cq = newCtrlQuad((uint)_WorldMapEdges.size());
cq->setModulateGlobalColor(false);
cq->setActive(_Active);
gm->addCtrl(cq);
cq->setParent(gm);
cq->setRenderLayer(1);
_WorldMapEdges.push_back(cq);
if (_WorldMapPoly)
{
cq->setId(_WorldMapPoly->getId() + toString("_e%d", _WorldMapEdges.size() - 1));
}
}
}
_WorldMapEdges.resize(count);
for(uint k = 0; k < count; ++k)
{
_WorldMapEdges[k]->setTexture(_Look.EdgeLook.WorldMapTexture);
_WorldMapEdges[k]->setColorRGBA(_Look.EdgeLook.WorldMapColor);
}
}