There are 2 scenarios:
1. the coordinates are relative to the camera - This means that the 2d positions will always be facing the camera in the exact same way no matter how much the camera rotates.
2. The coordinates are relative to the object - This means that the 2d positions will always be at the object's corners. They will rotate as the object rotates or as the camera angle changes.
When you ask
Quote: "anyway how would you take the camera angle and use it to find out where those corners are?"
It makes me think you are asking about scenario 1.
In any case, the way to do it is:
1. Find the center of the object (x y z)
2. Find the dimensions of the object (x y z) use object size x() object size y() object size z()
3. Divide each object size value by 2.0
4. use the 3 half sizes to calculate the distance to a corner
sqrt(halfx#^2 + halfy#^2 + halfz#^2)
5. find the slope between halfx and halfz (y angle to the corner) and convert that to an angle
ang#=atanfull(halfx#,halfz#)
6. use newxvalue and newzvalue and the camera angle or the object angle (depending on scenario 1 or 2) and the slope angle and the distance to find the x and z of the corner positions
7. position the scensor object(s) at the corner positions
8. get the 2d screen positions of the scensor object(s)
If you have trouble figuring out the details, let me know. I wrote up a function to test out the idea and it works fine so the method seems sound.
Enjoy your day.