Load Object "DataModelsM" + Str$(T2) + ".x",Num
If Image Exist(T2 + 900) = 0
If File Exist("DataModelsM" + Str$(T2) + ".bmp") = 1
Load Image "DataModelsM" + Str$(T2) + ".bmp",T2 + 900
Else
Log("Error [008]",2)
ExitFunction
EndIf
EndIf
Texture Object Num,T2 + 900
Scale Object Num,2500,2500,2500
XRotate Object Num,90
Fix Object Pivot Num
Position Object Num,X * 50,(Y * 50) - 25,Z * 50
The above code loads a model and texture, then textures and positions it properly. Well what happens is the model is loaded, and the texture (apparently) is loaded, as it reports no error in the log file -"Log("Error [008]",2)" does that - but leaves me with a great model and no texture. The same code in a different place works (there are three of these bits of code in the one function, one of them deals with primatives, the other with entities) and they both work fine. As well, the charactor loading routine works and uses almost the exact same code, but with hard-coded image and model locations. So I changed these to hard-coded as well and no change. Any ideas?
[EDIT] As well, these images and models DO exist for sure!!! I checked to make sure that the ""DataModelsM" + Str$(T2) + ".bmp"," line outputed the right results, it did.
Alex Wanuch
aka rapscaLLion
Kousen Dev Progress >> Currently Working On Editors