Hi - Another issue - i cant even think of key words to search google to try find solution
m_GSelected is a GGroup* class which has a std::vector<GBody*> m_GBodies;
Function
std::vector<GBody*> getBodies() { return m_GBodies; };
m_GSelected->getGAgents().push_back(body);
Why does this not add anything to the vector. I use the debugging tool in Visual Studio, to walk through it and everything is fine and nothing gets added. Vector stays empty size 0
I am using work around like so
std::vector<GBody*> m_PlaceholderBodies = m_GSelected->getBodies();
m_PlaceholderBodies.push_back(body);
m_GSelected->setBodies(m_PlaceholderBodies );
This works
Thanks for any pointers that you may have to this issue