I have made a matrix editor in the copyof DBC that I own however line 69 exceeds 255 characters in length. My DBPro trial has almost run out and if anyone with DBPro could compile this code into an exe for me I would appreciate that so that I can keep running the file I made.
I have read the Acceptable usage policy and have not found anything saying that I could not ask someone to do this. If there is a problem with me asking this question I am sorry.
sync on
for g = 1 to 100
ink rgb(0,rnd(255),0),0
box rnd(25),rnd(25),rnd(25),rnd(25)
next g
get image 1,0,0,25,25
make matrix 1,100.0,100.0,10,10
prepare matrix texture 1,1,1,1
position camera 50,20,50
autocam off
make object sphere 1,5
press = 0
x=0
z=0
h = 0
do
ay# = camera angle y()
ax# = camera angle x()
if upkey()=1 and press = 0 and z < 10 then move object 1,10 ; press = 1 ; z = z + 1 ; h = get matrix height(1,x,z)
if rightkey()=1 and press = 0 and x < 10 then yrotate object 1,90 ; move object 1,10 ; press = 1 ; yrotate object 1,0 ; x = x + 1 ; h = get matrix height(1,x,z)
if leftkey()=1 and press = 0 and x > 0 then yrotate object 1,270 ; move object 1,10 ; press = 1 ; yrotate object 1,0 ; x = x - 1 ; h = get matrix height(1,x,z)
if downkey()=1 and press = 0 and z > 0 then move object 1,-10 ; press = 1 ; z = z - 1 ; h = get matrix height(1,x,z)
if spacekey()=1 and press = 0 then gosub savematrix
if inkey$()="a" then h = h + 1 ; set matrix height 1,x,z,h
if inkey$()="z" then h = h - 1 ; set matrix height 1,x,z,h
if mousex()>320 then yrotate camera wrapvalue(ay#+(mousex()-320)/100)
if mousex()<320 then yrotate camera wrapvalue(ay#-(320-mousex())/100)
if mousey()>240 then xrotate camera wrapvalue(ax#+(mousey()-320)/100)
if mousey()<240 then xrotate camera wrapvalue(ax#-(320-mousey())/100)
if mouseclick()=1 then move camera 1
if mouseclick()=2 then move camera -1
position object 1,x*10,get matrix height(1,x,z),z*10
text 0,0,str$(x)
text 0,20,str$(z)
text 0,40,str$(h)
if scancode()=0 then press = 0
update matrix 1
sync
loop
savematrix:
if file exist("Matrix.txt")=1 then delete file "Matrix.txt"
open to write 1,"Matrix.txt"
dim ha(10,10)
for x = 0 to 10
for z = 0 to 10
ha(x,z) = get matrix height(1,x,z)
next z
next x
for x = 0 to 10
write string 1,STR$(ha(x,0))+","+STR$(ha(x,1))+","+STR$(ha(x,2))+","+STR$(ha(x,3))+","+STR$(ha(x,4))+","+STR$(ha(x,5))+","+STR$(ha(x,6))+","+STR$(ha(x,7))+","+STR$(ha(x,8))+","+STR$(ha(x,9))+","+STR$(ha(x,10))+","
next x
end
return
"Computers in the future may weigh no more then
1.5 tons.
- Popular Mechanics, 1949