Load a 2d Texture in game.

I have public Texture2D[ ] balloonTextures; and I assigned the correct images to each element, but how can i call a function then place the image in a specific location?

I got it working. I used balloonTextures[0].transfor.position = new Vector3();

Instead of using = Vector3(); is there a way to work in screen space?

Can you give more details on how you want the texture to work in screen space?

I want to be able to place it at say 0,0 and then the next image in the array at 49, 0 and so on.

Store the points in a vector3 array. When you want the image to display, display the image and the position of the vector3 array. For example, in your case:

Vector3[] storagePos = new Vector3[numOfPoints];
storagePos[0] = (0, 0, 0);
storagePos[1] = (49, 0, 0);
balloonTextures[0].transform.position = storagePos[0];
balloonTextures[1].transform.position = storagePos[1];

That keeps giving me an Error @ storagePos[0] = (0, 0, 0); Unexpected symbol ‘,’, expecting ‘)’

sigh Why are you even copying it straight?

storagePos[0] = new Vector3(0, 0, 0);

Or…

storagePos[0].x = 0;
storagePos[0].y = 0;
storagePos[0].z = 0;

I fixed that but Im looking for a way to set the location of the image on a 0 to 800 and 0 to 600 scale for a 800x600 resolution window.

Find out specifically, where in the scale you want the image to be placed. After that, use this formula:

storagePos[currentImage].x = (storagePos[currentImage].x / TEXTURE_WIDTH) * Screen.width;
storagePos[currentImage].y = (storagePos[currentImage].y / TEXTURE_HEIGHT) * Screen.height;

Then read up on this: Unity - Scripting API: Screen