ok,this is 64 lines because i couldn't get the compressor programs to work, if anyone could compress this for me that would be great.
Basically what this program does is take a bitmap, then using its rgbr color value, assign a size for that pixel (0 being small 255 being HUGE), and assign a height for that pixel based on the rgbb color value. It isn't perfect or complete yet.
-BTW, don't do the multilayer thing, I started but never finished it.
Any suggestions as to how I can make this better would be greatly appreciated. When I get around to it, I will add a texture part but probably not soon.
here is the code
Print "Easy Level creation system"
Print "Enter image file name(must be .bmp)"
input file_name$
Print "Is this a multi layered map?(y/n)"
input yn$
if upper$(yn$)="Y"
basename$=file_name$
file_name$=basename$+"\"+basename$+str$(levelnumber)
endif
file_name$=file_name$+".bmp"
load image file_name$,1
ink rgb(255,0,0),rgb(0,0,0)
cls;sprite 1,0,0,1
set sprite 1,1,0;hide mouse
dim size(sprite height(1)+10,sprite width(1)+10)
dim d(sprite height(1)+10,sprite width(1)+10)
x=0
y=0
sync on
sync rate 0
sh=sprite height(1)
sw=sprite width(1)
load bitmap file_name$,0
for h=1 to sprite height(1)+5
for w=1 to sprite width(1)+5
color=point(x,y)
size(h,w)=rgbr(color)
d(h,w)=rgbb(color)
draw to front
text 400,10,str$(x)+" "+str$(y)
dot x,y
x=x+1
sync
next w
x=0
y=y+1
sync
next h
sync
delete sprite 1
cls
on=1
for h=1 to sh
for w=1 to sw
make object cube on,1
sv=size(h,w)
text 0,0,str$(sv)
sync
scale object on,100,sv,100
position object on,w,d(h,w),h
on=on+1
sync
next w
next h
sync
set camera range 1,5000
position camera camera position x(),camera position y()+5,camera position z()
do
if upkey()=1 then move camera 1
if downkey()=1 then move camera -1
if rightkey()=1 then turn camera right 1
if leftkey()=1 then turn camera left 1
sync
loop
As I said before, someone PLEASE compress this for me.
Thanks