   is there a way to  make funtions look like there from 2 classes but  really only one ?
  i hace a base class , which   get createda  lot ,  10 times a second min. sometimesinside it i  have 2 static dequesso that no mater  how many times it get called  there  is only on of the deques , 1  and 2 one called model , other is mesh i would like to write funtions  for these ,  each have there own funtions.at the momemt , it looks like baseclass->modelMove()baseclass->modelPosition();baseclass->meshMove()baseclass->modelPosition()i would like   baseclass->model()->move();baseclass->model()->Position();baseclass->mesh()->Move()baseclass->model()->Position()i know i can do this if i have 2  classes   inside  the base class, but they would have to be static , which i  have been told  can be done ,  but a little messy can anyone tell me the best way to do this plaese?   
  If move() and position() are functions of whatever object is in your deque, then if you return the object in your model() and mesh() functions, that should work. Just return the object you were using in modelMove(). You may need to have them inherit a common class to access move and position.As for the static part, you may have some architectural issue. A class needing a static deque to function is as error prone as global variables. You may want to put that functionality in a manager class and keep references to the model and mesh that your objects need.   ;  The simple answer is to add functions such as this to your base class:void modelMove(){    model()->move();}And then you wont be breaking the Law of Demeter.   ;  Are the model and mesh ever going to move separately? Why not create a move() method in the base class and have it call move() on both the model and mesh?Still, I find your design strange. There should be no need for a global deque<> here.   ;  Yes, make a new class that inherits from deque.Then add the move() and position() functions to that class.Then make mesh() and model() functions that return the respective class instances.   ;  Don't inherit from deque<>. The Standard C++ Library containers are not designed for inheritance. They lack virtual destructors.   ;Don't inherit from deque<>. The Standard C++ Library containers are not designed for inheritance. They lack virtual destructors.ok my fault  ,  explained it wrong more likeModelGetPosition();ModelGetVectorZ();GetDistanceBeteenModels(IModel* model1, IModel* model2);GeshGetMaxLife();meshGetSphereRadius();and would like to seperate , like  GetModel->GetPosition();GetMesh()->GetSphereRadius();i have tryed to create them seperate and put them into a class , via singleton , but  keep getting a circular dependancy issue.there too close,   ;  You need to post more code. Post the class definitions involved. It is hard to infer your overall architecture from your description.   ;  Next, why are you creating so many of these?  Just wondering.   ;private:int    m_health;floatm_lifeSoFar;unsigned intm_meshNumber;boolm_isAlive;IModel*mp_model;float  m_maxTime;bool isBothEffects(UINT& origin,UINT& ModelNum);bool isShereToSphereCollision(UINT& origin, UINT& ModelNum);bool isEffect() { return gp_MeshManager[m_meshNumber]->m_isEffect;}protected:voidModelSetToDead() { m_isAlive = true;}floatModelGetLifeSoFar()    { return m_lifeSoFar;}int ModelGetHealth() { return m_health;}void    ModelSetHealth(int health) {m_health = health;}void    ModelDecrementHealth(int damage){ m_health -= damage;}float    MeshGetLifeInSeconds() { return gp_MeshManager[m_meshNumber]->m_TotalLifeInSeconds;}bool   MeshGetIsCollidAble() { return gp_MeshManager[m_meshNumber]->m_isCollidable;}bool   MeshGetIsSphere(){ return gp_MeshManager[m_meshNumber]->m_isSphere;}float   MeshGetSphereRadius() { return gp_MeshManager[m_meshNumber]->m_sphereRadius;}D3DXVECTOR3 MeshGetBoundingBoxMin()    { return gp_MeshManager[m_meshNumber]->m_boundingBoxMin;}D3DXVECTOR3 MeshGetBoundingBoxMax()    { return gp_MeshManager[m_meshNumber]->m_boundingBoxMax;}floatMeshGetMaxSpeed()  { return gp_MeshManager[m_meshNumber]->m_maxSpeed;}IMesh* GetMesh()    { return gp_MeshManager[m_meshNumber]->m_mesh;}intMeshGetCreationSound() {return gp_MeshManager[m_meshNumber]->m_creationSound;}// sound waveintMeshGetDeletionSound() {return gp_MeshManager[m_meshNumber]->m_deletionSound;}// sound wavebool   MeshGetUsesHealth()   {return gp_MeshManager[m_meshNumber]->m_usesHealth;}intMeshGetDamageDone()   {return gp_MeshManager[m_meshNumber]->m_damageDone;}bool   MeshGetIsEffect(){return gp_MeshManager[m_meshNumber]->m_isEffect;}intMeshGetStartingHeath() {return gp_MeshManager[m_meshNumber]->m_startHealth;}[size=2]Next, why are you creating so many of these? Just wondering. <br />[size=2]<br />[size=2]its cause its part of an entity manager i created ,  it keeps  track of all my  present models  on the  screen and the  Hard const data used to create them 