Quantcast
Channel: Programming Forums
Viewing all articles
Browse latest Browse all 51036

error creating a vector in visual c++ 2010

$
0
0
just as the name says,

class ROOM : public OBJECT_ID
{
public:
	ROOM() : OBJECT_ID(OT_ROOM)
	{
		// ERROR CODE
	}
	ROOM(bool enter) : OBJECT_ID(OT_ROOM)
	{
		if (enter == true) in_room = true;
		if (enter == false) in_room = false;
	}
	ROOM(int size) : OBJECT_ID(OT_ROOM)
	{
		
	}
	~ROOM();
private:
	bool in_room;
	vector<int> room_size;
}



its a snippet but it shows what im asking, at the bottom vector<int> room_size gives me an error, saying its "not a template" and im not even sure what that means. I tried to "bite the bullet" and use a std:: prefix on it but that didnt work either. suggestions?

Viewing all articles
Browse latest Browse all 51036

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>