// na przykald public void RenderBoard(Gameboard board, List<Player> players) { Rectangle srcRect; Bitmap icon; //picture.Image = icon; //Bitmap = Graphics.Draw for (int x = 0; x < board.board.GetLength(0); x++) for (int y = 0; y < board.board.GetLength(1); y++) { switch (board.getBoard()[x,y]) { case tilesState.empty: { OverDraw(originalBoard, iconFloor, x * 32, y * 32); //picture.Paint( break; } case tilesState.obstacle: { OverDraw(originalBoard, iconWall, x * 32, y * 32); break; } case tilesState.player: { OverDraw(originalBoard, iconPlayer1, x * 32, y * 32); break; } case tilesState.zombie: { OverDraw(originalBoard, iconMedusa1, x * 32, y * 32); break; } } } picture.Image = originalBoard; picture.Invalidate(); }
public Game(List<Player> playerCont, int sizeX, int sizeY,int zombieNumb,int playersNum) { playerContainer = playerCont; gameBoard = new Gameboard(sizeX, sizeY, zombieNumb, playersNum); }