Re-Dim (*solved*)
DIM grid (3,3) as uByte
SUB reinitialiseGrid ()
DIM grid (3,3) as uByte => { {0,1,2,3}, {4,5,6,7}, {8,9,10,11}, {12,13,14,15} }
END SUB
Is that legal, or is it trying to make a local variable?
DIM grid (4) as uByte => {0,1,2,3,4}
DIM gridcopy(4) as uByte
gridcopy=grid
ink 1
for n=0 to 4
print grid (n);" ";
next n
print
print
ink 2
for n=0 to 4
print gridcopy (n);" ";
next n
print
print
gridcopy(0)=10
gridcopy(1)=20
gridcopy(2)=30
gridcopy(3)=40
ink 1
for n=0 to 4
print grid (n);" ";
next n
print
print
ink 2
for n=0 to 4
print gridcopy (n);" ";
next n
gridcopy=grid
print
print
ink 1
for n=0 to 4
print grid (n);" ";
next n
print
print
ink 2
for n=0 to 4
print gridcopy (n);" ";
next n
Users browsing this forum: No registered users and 0 guests