![PoGa 4DGL Reference Manual Download Page 17](http://html1.mh-extra.com/html/poga/4dgl/4dgl_reference-manual_1570571017.webp)
Portable Game Console
PoGa-4DGL Reference Manual
Modify the TextTiler program
Open TextTiler.4DG in workshop (if it isn’t still open).
Add the following code at the start of the main procedure (immediately after the vars) .
if(media_Init() == 0)
// initialise and test the uSD card
print("No uSD CARD\n");
while(1);
endif
for(i := 0; i < TileNY; i++)
for(j := 0; j < TileNX; j++)
media_VideoFrame(j*TileSX, i*TileSY, i*j);
next
next
pause(2000) ;
This shows the puzzle as it will look when complete, just in case it looks too messed up to understand when
it is randomised.
Replace the Initial tile writing at line 46 (if using the sample code, or approximately line 37 if cutting and
pasting from this doc).
pokeB(TEXT_XMAG,3) ;
pokeB(TEXT_YMAG,3) ;
gfx_MoveTo(j*TileSX, i*TileSY) ;
print([CHR] chars[posn[i*j]]);
With
media_VideoFrame(j*TileSX, i*TileSY, posn[i*j]);
© 2011 4D Systems
www.4dsystems.com.au
Page 17 of 87