First of all, you should probably make a matrix to set the object on. Also, do put the model in the same directory as your project. You may also need to scale up the model, as sometimes loaded objects get placed into a program VERY small (maybe scale up 900,900,900). Try this:
Sync On
Sync Rate 30
Rem make matrix
Make matrix 1,10000,10000,20,20
Rem texture matrix
Load image "grass09.bmp",1
Prepare matrix texture 1,1,1,1
Fill matrix 1,0,1
Rem Randomize the matrix
randomize matrix 1,125
rem load your image (MUST BE A .X file. .MDL is not supported I rem don't think)
load object "RD_P-51D.mdl",1
position object 1,500,0,500
scale object 1,100,100,100
position camera 450,20,450
REMSTART MAYBE EVEN ADD THIS TO THE CODE TO
YOUR CODE TO MAKE THE CAMERA POINT AT
THE OBJECT
REMEND
mdX# = object position X(1)
mdY# = object position Y(1)
mdZ# = object position Z(1)
rem now point the camera now that we have the
rem object's position
point camera mdX#,mdY#+25,mdZ#
Rem Main loop
Do
set cursor 0,0
print X#
print Y#
print Z#
Rem Store Object angle
CameraAngleY# = Camera angle Y()
Rem Control input for camera
If Upkey()=1
XTest# = Newxvalue(X#,CameraAngleY#,20)
ZTest# = Newzvalue(Z#,CameraAngleY#,20)
If XTest#>0 and XTest#<10000 and ZTest#>0 and ZTest#<10000
Move camera 10
Endif
Endif
If Leftkey()=1 then Yrotate Camera Wrapvalue(CameraAngleY#-5)
If Rightkey()=1 then Yrotate Camera Wrapvalue(CameraAngleY#+5)
X# = Camera position X()
Z# = Camera position Z()
Y# = Get ground height(1,X#,Z#)
Position Camera X#,Y#+35,Z#
Rem Refresh Screen
Sync
Loop
Maybe try that out. That was mostly taken from this tutorial:
http://developer.thegamecreators.com/?f=t01/3d_tutorial_index Mayeb try out doing that tut first! Hope this helps!
P.S.- What this code is going to do is make a matrix for your model to be on, then lets you move the camera around with the arrow keys so you can view it from every angle! This is a great first program for loading a model. Also, you will need some kind of texture to replace "grass09.bmp". You can replace it with whatever you want to texture the matrix with! Have fun and post again to let me know how it turns out.