How to dynamically add to arrays
Hi Guys,
I've got the following code:
Code:
float tankRoute [4][3] = {
{0.450897f, 0.066000f, 0.023682f},
{0.203909f, 0.086718f, 0.021484f},
{0.321878f, 0.463296f, 0.027344f},
{0.450897f, 0.066000f, 0.023682f},
};
What I need to be able to do is to add additional entires dynamically ie a click on the mouse will give me 3 points that I need to append to the end of my array.
Thought you might be able to use a vectot but failed at the first hurdle :-(
Tried the following (firstly calling #include<vector>:
vector <float> tankRoute2;
but got the following errors:
error C2065: 'vector' : undeclared identifier
error C2062: type 'float' unexpected
Any ideas how I can go about doing this please?
Cheers