I've already posted this code in the newcomers section with no reply. But here it is again. I'd rather use variables, but I've tried putting straight integers in the image number slots. Once, I got DBP Demo to load the texture, but once I tried to texture the object - exception. I tried unique numbers not used anywhere else in the program. Didn't work. Sometimes it exceptions, sometimes, DBPro Demo just sits there with a black screen.
And when I tried to use global in front of any of these variables, I got a compile error four lines about the use of global that said "#100025: Declaration name " is not valid at line X" where X is 4 lines less than the line global sits on. I could not find any help on the use of global or constant.
Also, the 3d model of the hovercraft loads fine. But when I load a texture from the same directory, it barfs. It sucks that the only time anyone has offered to help me is when I've bitched about the problems DBPro Demo has.
Outcast
HOVERCRAFT_OBJ_ID = 102
dim HOVERCRAFT_RADIUS(0) : HOVERCRAFT_RADIUS(0) = 5
load object "media/hovercraft.3ds", HOVERCRAFT_OBJ_ID
scale object HOVERCRAFT_OBJ_ID,175,175,175
position object HOVERCRAFT_OBJ_ID, 250,1,250
HOVERCRAFT_TEXTURE_ID = 1
load image "media/hovercraft_1.bmp", HOVERCRAFT_TEXTURE_ID
texture object HOVERCRAFT_OBJ_ID, HOVERCRAFT_TEXTURE_ID
LOAD IMAGE
This command will load a picture file as an image. The picture file must be of the BMP, JPG, TGA, DDS, DIB or PNG format. All images loaded are prepared with mipmaps if
they do not already have them, and stored with all pixel data intact. This differs from loading DDS image files which are stretched to the textures they occupy.
SYNTAX
LOAD IMAGE Filename, Image Number
LOAD IMAGE Filename, Image Number, Texture Flag