Well this very simple AI do just what you need:
`Very, very basic "AI"
`Normal settings
sync on
sync rate 60
hide mouse
`\\\\
`Make a matrix
make matrix 1,1000,1000,10,10
position matrix 1,0,-10,0
`\\\\
`Make the player object
make object box 1,10,10,10
color object 1,rgb(0,155,0)
`\\\\
`Make enemy object
make object box 2,10,10,10
color object 2,rgb(255,0,0)
position object 2,40,0,-60
`\\\\
`Camera settings
autocam off
position camera 0,100,0
`\\\\
`**Main Loop**
do
`More camera settings
point camera object position x(1),object position y(1),object position z(1)
`\\\\
`Player control
if keystate(200)=1
move object 1,2
endif
if keystate(203)=1
turn object left 1,2
endif
if keystate(205)=1
turn object right 1,2
endif
`\\\\
`Basic enemy AI
point object 2,object position x(1),object position y(1),object position z(1)
move object 2,1
`\\\\
sync
loop
`**End Of Main Loop**
Now when you got the very basic, maybe you could try and build on the AI to make it better?
-The Nerd
PanzerGames
here
Free Particle Engine For dbpro :
here