private void setLevelSpawn(){
        data.nextLevel();
        bossLevel       = data.ifBoss();    //checking if its a boss level, every 10 levels        
        currentElement  = data.getType();   //1 is air, 2 is water, 3 is fire, 0 is earth
        nextElement     = data.getNextType();
        maxSpawnCount   = data.getMaxSpawn();
        spawnRate       = data.getSpawnRate();
        numCreeps       = mobsToSpawn.size();       //the number of mobs the user sent

        ui.setWaveData (currentElement, nextElement, level);

        money += income;
        ui.setGeneralData (lives, money, income);
        cb.setMessage ("Level " + level + " Starting", 2);

        for (int i = 0; i < maxSpawnCount; i++){
            Enemy newEnemy = null;
            //add what type of enemy to make
            if      (currentElement == 1){
                newEnemy = new AirMob   (data.getHp(), data.getArmor(), data.getSpeed(), 
                    data.ifBoss(), data.ifFlying() );
            }
            else if (currentElement == 2){
                newEnemy = new WaterMob (data.getHp(), data.getArmor(), data.getSpeed(), 
                    data.ifBoss(), data.ifFlying() );
            }
            else if (currentElement == 3){
                newEnemy = new FireMob  (data.getHp(), data.getArmor(), data.getSpeed(), 
                    data.ifBoss(), data.ifFlying() );
            }
            else if (currentElement == 4){
                newEnemy = new EarthMob (data.getHp(), data.getArmor(), data.getSpeed(), 
                    data.ifBoss(), data.ifFlying() );            
            }
            mobsToSpawn.addFirst (newEnemy);
        }

        //adds the numbers of mobs to spawn to the max spawn count
        maxSpawnCount += numCreeps;

        List <Tower> tempTower = getObjects (Tower.class);
        for (Tower t: tempTower){
            t.setActive (true);
        }
        //System.out.println (level);
        wp.setMax (maxSpawnCount);
    }