You're welcome nolddor ! 

I hope you enjoy this little Demo !
Today, I work for a generation Map's Engine.
The size map is : 320 x 512 and I manage the VRAM Memory to get 13 tile of 32 x 32 for the stage !
Here is the Base Tile :
 
It's a base for my work, but I can make many more ( I'm a pixel artist too ... )
And the video demo :
http://youtu.be/QJz1BPqtSu0
( with a little Scrolling. )
For that, I use a DATA like this :
Code: Select all
Map1:
 DATAINT 7,0,0,1,0,0,1,0,6,0 'End
 DATAINT 0,2,2,2,0,0,2,2,2,0
 DATAINT 0,6,0,0,7,0,0,8,0,0
 DATAINT 12,0,0,0,0,0,0,0,0,0
 DATAINT 8,0,1,0,3,5,0,1,0,0
 DATAINT 0,0,1,0,0,0,0,1,0,0
 DATAINT 2,2,2,7,0,0,0,2,2,2
 DATAINT 0,0,0,0,0,0,0,0,0,0
 DATAINT 0,1,0,0,9,0,0,1,0,0
 DATAINT 0,1,6,0,0,0,0,1,0,0
 DATAINT 0,3,4,4,4,4,4,4,5,0
 DATAINT 10,0,0,0,0,0,0,0,0,6
 DATAINT 8,0,0,1,0,0,1,0,11,0
 DATAINT 0,2,2,2,0,0,2,2,2,0
 DATAINT 0,2,0,0,0,0,0,0,2,0
 DATAINT 0,7,0,0,8,0,0,0,0,0 'Start
Code: Select all
global A as integer
 global T(200) as integer
 
 '13 tiles de 32x32 : 208 Tiles en mémoire.
 
 loadtiles Decor6,32,160 '0 Terrain neutre
 loadtiles Decor7,32,192 '1 Sac Double
 loadtiles decor8,32,224 '2 Sac Simple
 loadtiles Decor1,32,240 '3 Barbelé droite
 loadtiles decor2,32,256 '4 Barbelé Milieu
 loadtiles decor3,32,272 '5 Barbelé gauche
 loadtiles decor10,32,288 '6 végétation 1
 loadtiles decor11,32,304 '7 végétation 2
 loadtiles decor12,32,320 '8 Végétation 3
 loadtiles decor4,32,336 '9 rocher 1
 loadtiles decor9,32,352 '10 rocher 2
 loadtiles decor13,32,368 '11 Sable 1
 loadtiles decor5,32,384 '12 Sable 2
 
 
Map1:
 DATAINT 7,0,0,1,0,0,1,0,6,0 'End
 DATAINT 0,2,2,2,0,0,2,2,2,0
 DATAINT 0,6,0,0,7,0,0,8,0,0
 DATAINT 12,0,0,0,0,0,0,0,0,0
 DATAINT 8,0,1,0,3,5,0,1,0,0
 DATAINT 0,0,1,0,0,0,0,1,0,0
 DATAINT 2,2,2,7,0,0,0,2,2,2
 DATAINT 0,0,0,0,0,0,0,0,0,0
 DATAINT 0,1,0,0,9,0,0,1,0,0
 DATAINT 0,1,6,0,0,0,0,1,0,0
 DATAINT 0,3,4,4,4,4,4,4,5,0
 DATAINT 10,0,0,0,0,0,0,0,0,6
 DATAINT 8,0,0,1,0,0,1,0,11,0
 DATAINT 0,2,2,2,0,0,2,2,2,0
 DATAINT 0,2,0,0,0,0,0,0,2,0
 DATAINT 0,7,0,0,8,0,0,0,0,0 'Start
 
 palettes pallettedata_decor,1,0,16
 
 setgfxplane Scroll_B
 setscrollplane Scroll_B
 setscrollmode hscroll_overall,vscroll_overall
 
 'Lecture de la Map
 reload Map1
 for i=1 to 160
 readint t(i)
 next
 
 'Init Scroll
 scroll down,224,scroll_b
 
 'Création de la carte 320 x 512
 for i=0 to 15
 for j=0 to 9
 'Compteur
 c++
 if t(c)=0 then drawtilesinc 160+palette(1), 0+(j*4), 0+(i*4), 4, 4
 if t(c)=1 then drawtilesinc 192+palette(1), 0+(j*4), 0+(i*4), 4, 4
 if t(c)=2 then drawtilesinc 224+palette(1), 0+(j*4), 0+(i*4), 4, 4
 if t(c)=3 then drawtilesinc 240+palette(1), 0+(j*4), 0+(i*4), 4, 4
 if t(c)=4 then drawtilesinc 256+palette(1), 0+(j*4), 0+(i*4), 4, 4
 if t(c)=5 then drawtilesinc 272+palette(1), 0+(j*4), 0+(i*4), 4, 4
 if t(c)=6 then drawtilesinc 288+palette(1), 0+(j*4), 0+(i*4), 4, 4
 if t(c)=7 then drawtilesinc 304+palette(1), 0+(j*4), 0+(i*4), 4, 4
 if t(c)=8 then drawtilesinc 320+palette(1), 0+(j*4), 0+(i*4), 4, 4
 if t(c)=9 then drawtilesinc 336+palette(1), 0+(j*4), 0+(i*4), 4, 4
 if t(c)=10 then drawtilesinc 352+palette(1), 0+(j*4), 0+(i*4), 4, 4
 if t(c)=11 then drawtilesinc 368+palette(1), 0+(j*4), 0+(i*4), 4, 4
 if t(c)=12 then drawtilesinc 384+palette(1), 0+(j*4), 0+(i*4), 4, 4
 
 next
 next
 
 
 while 1
 
 if joypad(0).0 then a++
 if joypad(0).1 then a--
 
 
 scroll up,a,scroll_b 
 sleep 2
 wend
 
 
pallettedata_decor:
   DATAINT   $0046,$0046,$0066,$0024,$0068,$0000,$0888,$0ECC
   DATAINT   $0444,$0222,$06A8,$048C,$02A4,$0262,$04AC,$0026
Where Values are the Number of Tiles ... Easy !
I can create a level in a few minutes.
So, for my project, I can use this engine to make some various stage.
See you !