heres the code, note that it is Pro
sync on
gosub make_background
gosub make_meshes
make matrix 10,1000,1000,100,100
position matrix 10,-500,0,-500
paste image 1,100,100
sync
make object 1,1,1
color object 1,rgb(255,0,0)
x=0 : z=0 : curlimb=0
position camera 0,20,2 : xrotate camera 90
ink 0,0
do
ink rgb(255,0,0),0 : if mouseover(10,10,100,20)=1 then box 9,9,101,21
box 10,10,100,20,rgb(255,0,0),rgb(0,255,0),rgb(0,0,255),rgb(255,255,255)
if upkey()=1 then inc z,1
if downkey()=1 then dec z,1
if rightkey()=1 then inc x,1
if leftkey()=1 then dec x,1
if spacekey()=1 and spaceflag=0 then gosub create_limb
if spacekey()=0 then spaceflag=0
if mouseover(10,10,100,20)=1 and mouseclick()=1 then gosub change_color
if curlimb>0 : offset limb 1,curlimb,x,0,z : else : position object 1,x,0,z : endif
color limb 1,curlimb,currentcolor
if curlimb>0 then position camera x+object position x(1),20,z+object position z(1)
if curlimb=0 then position camera x,20,z
xrotate camera 90
sync
loop
make_meshes:
`basic block - mesh 1
make object cylinder 1,1 : scale object 1,100,30,100 : make mesh from object 1,1 : delete object 1
make object box 1,5,2,4
for x =1 to 6 : add limb 1,x,1 : next x
offset limb 1,1,-1.5,1.15,.5 : offset limb 1,2,0,1.15,.5 : offset limb 1,3,1.5,1.15,.5
offset limb 1,4,-1.5,1.15,-.5 : offset limb 1,5,0,1.15,-.5 : offset limb 1,6,1.5,1.15,-.5
color object 1,rgb(125,255,0)
make object sphere 2,.2 : make object sphere 3,.2
position object 2,-2.5,1,2 : position object 3,2.5,-1,-2
hide object 2 : hide object 3
position camera 0,30,-45
point camera object position x(1),object position y(1),object position z(1)
get image 1,object screen x(2)-2,object screen y(2)-2,object screen x(3)+2,object screen y(3)+2
delete mesh 1
make mesh from object 1,1
delete object 1 : delete object 2 : delete object 3
return
make_background:
cls
ink rgb(255,255,255),0
box 0,0,49,49
box 50,50,99,99
get image 2,0,0,100,100
cls
return
create_limb:
if curlimb=0 then x=0 : y=0
inc curlimb
spaceflag=1
add limb 1,curlimb,1
return
change_color:
clickflag=1
box 0,0,640,480,0,0,0,0
box 30,30,610,225,rgb(255,0,0),rgb(0,255,0),rgb(0,0,255),rgb(255,255,255)
box 30,255,610,450,0,0,rgb(255,255,255),rgb(255,255,255)
repeat
if mouseclick()=0 then clickflag=0
sync
until mouseclick()=1 and clickflag=0
currentcolor=point(mousex(),mousey())
cls
return
function mouseover(x1,y1,x2,y2)
if x1<mousex() and mousex()<x2
if y1<mousey() and mousey()<y2
exitfunction 1
endif
endif
endfunction 0
[Edit]
weird, for some reason if u move the box drawing codes into the repeat...until loop then they show up
still having trouble with getting the color of the point below mouse, point does work on 2d, right cuz its going thru the 2d and giving me the color of the backdrop
There are only 10 kinds of people in the world, those who understand binary and those who dont