><code data-line-numbers="3-6|8-51|53-64|66-69">
generateMap() {
  for (let i in this.map) {
    for (let v in this.map[i]) {

      let building;

      if (this.map[i][v] == 'x') {

        //place building
        let bdiv = document.createElement('building');
        building = new THREE.CSS3DObject(bdiv);

        let topdiv = document.createElement('div');
        topdiv.className = 'top';
        let top = new THREE.CSS3DObject(topdiv);
        top.position.z = -200;
        top.rotation.x = 180 * Ma