I solved that problem... but now I got a different problem. But first to say, IT WORKS!!!... for 270 degrees. I can turn around for 270 dgerees while the plain is looking at the camera and the picture changes... just when you get to the 3 image, the plain rotates and you don't get to see it! Since I have nothing to hide in the source code, I'm putting it all on here... including stuff you don't need but just to let you know what it does.
kyodukai-seikon.dbpro (Project File)
kyokudai-seikon.dba (Main Source File)
Rem Project: Kyokudai-Seikon
Rem Created: 8/11/2004 1:09:54 AM
Rem Written: Derek Ferrom
Rem ***** Main Source File *****
Rem Load Images
gosub _imageload
Rem Initialize Game
sync on
sync rate 80
autocam off
herolook = 0
herolook = wrapvalue(herolook)
herox = 0
heroy = 0
heroz = 0
camerax = camera position x()
cameray = camera position y()
cameraz = camera position z()
cameralookx = camera angle x() + mouselookx
cameralookx = wrapvalue(cameralookx)
cameralooky = camera angle y() + mouselooky
cameralooky = wrapvalue(cameralooky)
cameralookz = camera angle z()
cameralookz = wrapvalue(cameralookz)
mouselookx = -400 + mousex()
mouselooky = 300 - mousey()
timeline = 0
position mouse 400,300
mouselookx = 400 + mousex()
mouselooky = 300 - mousey()
Rem Start Game with Intro
Rem goto _introstart
make object box 1,1000,1,1000
texture object 1,5
make object plain 2,5,10
yrotate object 2,cameralook
position object 2,0,5,0
position camera 0,10,0
xrotate camera 0
yrotate camera 0
zrotate camera 0
Rem Loop to test Maps and how they look with nothing else.
do
yrotate object 2,cameralook
herolook = 0
herox = 0
heroy = 0
heroz = 0
herolook = wrapvalue(herolook)
cameralook = camera angle y()
cameralook = wrapvalue(cameralook)
pointsprite = cameralook - herolook
pointsprite = wrapvalue(pointsprite)
if pointsprite > 334 and pointsprite < 44 then texture object 2,1
if pointsprite > 45 and pointsprite < 134 then texture object 2,2
if pointsprite > 135 and pointsprite < 214 then texture object 2,3
if pointsprite > 215 and pointsprite < 335 then texture object 2,4
camerax = camera position x()
cameray = camera position y()
cameraz = camera position z()
cameralookx = camera angle x() + mouselookx
cameralookx = wrapvalue(cameralookx)
cameralooky = camera angle y() + mouselooky
cameralooky = wrapvalue(cameralooky)
cameralookz = camera angle z()
cameralookz = wrapvalue(cameralookz)
mouselookx = -400 + mousex()
mouselooky = 300 - mousey()
position mouse 400,300
looky = mousemovey() / 4
lookx = mousemovex() / 4
if rightkey()=1 then gosub _turncameraright
if leftkey()=1 then gosub _turncameraleft
if upkey()=1 then gosub _movecamerafoward
if downkey()=1 then gosub _movecameraback
if keystate(30)=1 then gosub _movecameraleft
if keystate(32)=1 then gosub _movecameraright
if keystate(17)=1 then gosub _movecameraup
if keystate(31)=1 then gosub _movecameradown
set cursor 0,0
print "Mouse X:"; mouselookx
print "Mouse Y:"; mouselooky
sync
loop
kyokudai-seikon-images.dba (Image Loading File)
Rem *** Include File: kyokudai-seikon-images.dba ***
Rem Created: 8/12/2004 7:20:19 PM
Rem Included in Project: kyokudai-seikon.dbpro
_imageload:
load image "testup.bmp",1
load image "testright.bmp",2
load image "testdown.bmp",3
load image "testleft.bmp",4
load image "grass.bmp",5
return
kyokudai-seikon-camera.dba (Camera Rotation/Moving File)
Rem *** Include File: kyokudai-seikon-camera.dba ***
Rem Created: 8/12/2004 9:31:20 PM
Rem Included in Project: kyokudai-seikon.dbpro
_turncameraright:
turn camera right 1
return
_turncameraleft:
turn camera left 1
return
_movecamerafoward:
move camera 1
return
_movecameraback:
move camera -1
return
_movecameraleft:
turn camera left 90
move camera 1
turn camera right 90
return
_movecameraright:
turn camera right 90
move camera 1
turn camera left 90
return
_movecameraup:
pitch camera up 90
move camera 1
pitch camera down 90
return
_movecameradown:
pitch camera down 90
move camera 1
pitch camera up 90
return
Help! Try it out yourself and provide your own images.
Pie!