sync on
set text opaque
`set size of map here
dim map(10,10)
`set to read map
for y=0 to 9
for x=0 to 9
read mapdata
map(x,y)=mapdata
next x
next y
load bitmap "idle.bmp",10
get image 10,0,0,44,80
sprite 10,300,100,10
scale sprite 10,50
set sprite 10,0,1
show sprite 10
load animation "move2.gif",1.
place animation 1,200,200,200,200
load animation "right.gif",2
place animation 2,200,200,200,200
`tiles
load image "grass08.bmp",1
load image "grass08.bmp",2
load image "grass08.bmp",3
`sprite 4,100,100,1
`make tiles, position them and texture them
for y=0 to 9
for x=0 to 9
objnum = objnum + 1
make object plain objnum,10,10
position object objnum,x*10,y*10,75
if map(x,y)> 0 then texture object objnum,map(x,y) else color object objnum,0
next x
next y
`set up camera and camera engine
do
rem Record old position
if upkey()=1 then position camera camera position x(),camera position y()+1,camera position z()
`if downkey()=1 then hide sprite 10
`if downkey()=1 then place animation 1,300,100,350,180
`if downkey()=0 then play animation 1
if downkey()=1 then position camera camera position x(),camera position y()-1,camera position z()
if leftkey()=1 then position camera camera position x()-1,camera position y(),camera position z()
if rightkey()=1 then position camera camera position x()+1,camera position y(),camera position z()
`if rightkey()=1 then hide sprite 10
`if rightkey()=1 then place animation 2,300,100,350,180
`if rightkey()=0 then play animation 2
`if rightkey()=0 then stop animation 2
if controlkey()=1 then print "hello"
xrotate camera 0.0
yrotate camera angle#
zrotate camera 0.0
sync
loop
make object plain 101,1,1
texture object 101,3
position object 101,1,1,76
`data for map
data 1,1,1,1,1,1,1,1,1,1
data 1,2,2,2,2,1,1,1,1,1
data 1,2,2,2,2,1,1,1,1,1
data 1,1,1,1,1,1,1,1,1,1
data 1,1,1,1,1,1,1,1,1,1
data 1,2,2,2,2,1,1,1,1,1
data 1,2,2,2,2,1,1,1,1,1
data 1,1,1,1,1,1,1,1,1,1
data 1,1,1,1,1,1,2,2,2,2
data 1,1,1,1,1,1,2,2,2,2
sync on
set text opaque
`set size of map here
dim map(10,10)
`set to read map
for y=0 to 9
for x=0 to 9
read mapdata
map(x,y)=mapdata
next x
next y
load bitmap "idle.bmp",10
get image 10,0,0,44,80
sprite 10,300,100,10
scale sprite 10,50
set sprite 10,0,1
show sprite 10
load animation "move2.gif",1.
place animation 1,200,200,200,200
load animation "right.gif",2
place animation 2,200,200,200,200
`tiles
load image "grass08.bmp",1
load image "grass08.bmp",2
load image "grass08.bmp",3
`sprite 4,100,100,1
`make tiles, position them and texture them
for y=0 to 9
for x=0 to 9
objnum = objnum + 1
make object plain objnum,10,10
position object objnum,x*10,y*10,75
if map(x,y)> 0 then texture object objnum,map(x,y) else color object objnum,0
next x
next y
`set up camera and camera engine
do
rem Record old position
if upkey()=1 then position camera camera position x(),camera position y()+1,camera position z()
`if downkey()=1 then hide sprite 10
`if downkey()=1 then place animation 1,300,100,350,180
`if downkey()=0 then play animation 1
if downkey()=1 then position camera camera position x(),camera position y()-1,camera position z()
if leftkey()=1 then position camera camera position x()-1,camera position y(),camera position z()
if rightkey()=1 then position camera camera position x()+1,camera position y(),camera position z()
`if rightkey()=1 then hide sprite 10
`if rightkey()=1 then place animation 2,300,100,350,180
`if rightkey()=0 then play animation 2
`if rightkey()=0 then stop animation 2
if controlkey()=1 then print "hello"
xrotate camera 0.0
yrotate camera angle#
zrotate camera 0.0
sync
loop
make object plain 101,1,1
texture object 101,3
position object 101,1,1,76
`data for map
data 1,1,1,1,1,1,1,1,1,1
data 1,2,2,2,2,1,1,1,1,1
data 1,2,2,2,2,1,1,1,1,1
data 1,1,1,1,1,1,1,1,1,1
data 1,1,1,1,1,1,1,1,1,1
data 1,2,2,2,2,1,1,1,1,1
data 1,2,2,2,2,1,1,1,1,1
data 1,1,1,1,1,1,1,1,1,1
data 1,1,1,1,1,1,2,2,2,2
data 1,1,1,1,1,1,2,2,2,2
this is what i have it kinda works but i cant get a a boundry i tried if x>500 then x=500 kinda stuf but didnt work
Daedalus