I can see how I can select an entity already placed using CameraPick()
What I want to know is how do I use MouseX/Y and then translate the viewport coordinates to terrain coordinates so I can select a place on the terrain.
I want to do a similar thing to populous where you can click the landscape to create a hill. I also want to be able to move the camera around.
I had a look at the code archive and found some code that purported to do what I wanted but only seemed to work when the camera was looking directly down on the scene which isn't what I want.
I know you can use a cameraproject to get from 3d to 2d there must be a way to do the reverse?
Any help would be greatly appreciated. Thankyou!
What I want to know is how do I use MouseX/Y and then translate the viewport coordinates to terrain coordinates so I can select a place on the terrain.
I want to do a similar thing to populous where you can click the landscape to create a hill. I also want to be able to move the camera around.
I had a look at the code archive and found some code that purported to do what I wanted but only seemed to work when the camera was looking directly down on the scene which isn't what I want.
I know you can use a cameraproject to get from 3d to 2d there must be a way to do the reverse?
Any help would be greatly appreciated. Thankyou!