set object should be used for hiding all black pixels from a textured object (see the help files for the right parameters, you have to set "transparency" to 0). I also think that ghosted objects don't show the black color.
The lock object should work... To get the height of the plain to fill the screen completely is
tan((3.14/2.905) * 180 / 2pi) * distance * 2, and the width is that value /3*4 (or
/screen height()*screen width()). Then texture the image with the HUD.
You can also start your loop with
paste image HUDImg, 0, 0
(the image has to be the size of the screen)
sync on : sync rate 0
`Create HUD
ink rgb(150, 150, 150), 0
cls
box 0, 0, 200, 50
ink rgb(0, 0, 0), 0
box 5, 5, 195, 15
box 5, 25, 195, 35
get image 1, 0, 0, screen width(), screen height(), 1
`Create locked plain
height# = tan((3.14/2.905)*90.0/3.141592654) * 10.0
make object plain 1, height#/3*4, height#
texture object 1, 1
set object 1, 1, 0, 0
lock object on 1
position object 1, 0, 0, 5
`The loop
do
sync
loop
or change the line
set object 1, 1, 0, 0 to
ghost object on 1 for a ghost effect on your HUD.
But ofcourse, if you don't need a ghost effect, it would be much simpler to do:
sync on : sync rate 0
`Create HUD
ink rgb(150, 150, 150), 0
cls
box 0, 0, 200, 50
ink rgb(0, 0, 0), 0
box 5, 5, 195, 15
box 5, 25, 195, 35
get image 1, 0, 0, screen width(), screen height(), 1
`Create sample cube
make object cube 1, 1
`The loop
do
paste image 1, 0, 0, 1
sync
loop
(note the 1 on the end of
paste image. It stands for transparency)
The variable data (like the radar dots or life) can be drawn in the loop itself.
It's the programmer's life:
Have a problem, solve the problem, and have a new problem to solve.