Can a Vector3 be a variable? I thought so, but I can't seem to find the correct syntax. How do I make this work?
for (float i = 0 ; i < blockX; i++)
{
Vector3 rowX = (i,0,0); //error on this line
Rigidbody instance = Instantiate (block,rowX, 0 );
}
This gives me the error: error CS1026: Unexpected symbol `,', expecting `)'
I have also tried skipping the declaration and just putting:
Rigidbody instance = Instantiate (block,Vector3(i,0,0),0);
That gives me more errors though.
↧