1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-25 15:35:23 +00:00

removed this stupide methode to generate unique ID.

This commit is contained in:
gugus 2011-05-23 19:47:27 +02:00
parent 4546ca3863
commit faaa08d6d0
2 changed files with 6 additions and 7 deletions

View File

@ -31,17 +31,14 @@ float ExteriorCellRender::lightQuadraticRadiusMult = 1;
bool ExteriorCellRender::lightOutQuadInLin = false;
int ExteriorCellRender::uniqueID = 0;
ExteriorCellRender::ExteriorCellRender(ESMS::CellStore<MWWorld::RefData> &_cell, MWWorld::Environment& environment,
MWScene &_scene)
: mCell(_cell), mEnvironment (environment), mScene(_scene), mBase(NULL), mInsert(NULL), mAmbientMode (0)
{
//char a = mCell.cell->name;
//char *rand1;
srand (150);
//itoa(rand(),rand1,10);
int a;
Ogre::StringConverter::toString(rand());
sg = Ogre::Root::getSingleton().getSceneManagerIterator().getNext()->createStaticGeometry( Ogre::StringConverter::toString(a));
uniqueID = uniqueID +1;
sg = Ogre::Root::getSingleton().getSceneManagerIterator().getNext()->createStaticGeometry( "sg" + Ogre::StringConverter::toString(uniqueID));
}

View File

@ -124,6 +124,8 @@ namespace MWRender
/// Remove the reference with the given handle permanently from the scene.
virtual void deleteObject (const std::string& handle);
static int uniqueID;
};
}