import javax.microedition.lcdui.*; public class LevelOne extends Canvas { private LayerManager LM; private TiledLayer TL; int width = getWidth(); int height = getHeight(); public LevelOne() { LM = new LayerManager(); TL = new TiledLayer(9, 9, Image.createImage("/fon.png"), 40, 40); LM.append(TL); LM.setViewWindow(0, 0, width, height); createFon; } public void createFon() { for (int row=0; row<10; row++) { for ( int col=0; col<10; col++) { TL.setCell(row, col, 1); } } } public void paint(Graphics g) { LM.paint(g, 0, 0); } }