Advertisement
Guest User

Untitled

a guest
Jun 30th, 2014
324
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.72 KB | None | 0 0
  1. void Game::render()
  2. {
  3.     window.clear();
  4.  
  5.     //this rebuilds the terrain vertex array
  6.     if (!mapObj.tmap.load(mapObj.tmap.getTileSet(),
  7.                           sf::Vector2u(64, 64),
  8.                           mapObj.getTerrainType(),
  9.                           mapObj.getMapWidth(),
  10.                           mapObj.getMapHeight()));
  11.  
  12.     //this rebuilds the npc vertex array
  13.     if (!mapObj.tmap.load(mapObj.tmap.getTileSet(),
  14.                           sf::Vector2u(64, 64),
  15.                           mapObj.getNpcType(),
  16.                           mapObj.getMapWidth(),
  17.                           mapObj.getMapHeight()));
  18.  
  19.     window.draw(mapObj.tmap);
  20.     window.draw(mapObj.nmap);
  21.     window.display();
  22. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement