Cannot declare std::vector<PhysicsShapePolygon> allShapes;

I cannot declare vector container for PhysicsShapePolygon in header, I am getting error.
where is problem?

std::vector<PhysicsShapePolygon> allShapes;

cocos2d::PhysicsShapePolygon::~PhysicsShapePolygon’: cannot access protected member declared

Error C2248 ‘cocos2d::PhysicsShapePolygon::~PhysicsShapePolygon’: cannot access protected member declared in class ‘cocos2d::PhysicsShapePolygon’ (compiling source file …\Classes\AppDelegate.cpp) …\xmemory0 951

Classes with protected destructor have their own reason, it might not be a proper way to do so.

thanks, I actually try to access sprite shape to count polygon points

This topic was automatically closed 60 minutes after the last reply. New replies are no longer allowed.