You can start by cleaning up your code,
I already did it for you
`¬¬¬¬¬¬¬¬¬¬Area Changing¬¬¬¬¬¬¬¬¬¬¬¬¬¬¬¬¬¬¬¬¬¬
sync on
sync rate 30
set display mode 1024,768,16
world1:
cls
load image "grass08.bmp",1
load image "ash01.bmp",2
dim world1(5,5)
for y=0 to 4
for x=0 to 4
if world1data < 1 then restore world1data
read world1data
world1(x,y)=world1data
next x
next y
for y=0 to 4
for x=0 to 4
objnum = objnum + 1
make object plain objnum,5,5
position object objnum,x*5,y*5,75
if world1(x,y)> 0 then texture object objnum,world1(x,y) else color object objnum,0
next x
next y
do
if mouseclick()=1
delete image 1
delete image 2
delete object objnum
undim world1(5,5)
goto world2
endif
` X,Y,ZOOM
position camera 0,0,-10
xrotate camera 0.0
yrotate camera angle#
zrotate camera 0.0
sync
loop
world2:
cls
load image "grass08.bmp",1
load image "ash01.bmp",2
dim world2(10,10)
for y=0 to 9
for x=0 to 9
if world2data < 1 then restore world2data
read world2data
world2(x,y)=world2data
next x
next y
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 world2(x,y)> 0 then texture object objnum,world2(x,y) else color object objnum,0
next x
next y
do
if mouseclick()=1
delete image 1
delete image 2
delete object objnum
undim world2(10,10)
goto world1
endif
position camera 0,0,-10
xrotate camera 0.0
yrotate camera angle#
zrotate camera 0.0
sync
loop
world1data:
data 1,2,1,2,1
data 2,1,2,1,2
data 1,2,1,2,1
data 2,1,2,1,2
data 1,2,1,2,1
world2data:
data 1,1,1,1,1,1,1,1,1,1
data 2,2,2,2,2,2,2,2,2,2
data 1,1,1,1,1,1,1,1,1,1
data 2,2,2,2,2,2,2,2,2,2
data 1,1,1,1,1,1,1,1,1,1
data 1,1,1,1,1,1,1,1,1,1
data 2,2,2,2,2,2,2,2,2,2
data 1,1,1,1,1,1,1,1,1,1
data 2,2,2,2,2,2,2,2,2,2
data 1,1,1,1,1,1,1,1,1,1
Now try to understand your own code.
-Every time you make a map you make something like 25 or 100 tiles.
-Every time you change to the other map you only delete 1 tile(the last one created).
The biggest fault is somewhere at the objnum intiger.
Try to reset it somewhere,somehow.