@Override
	public void update() {
		if(!isBattleOver){
			//For every game object in gameObjects
			for(GameObject obj : objects)
			{
				obj.update();
			}
			
			//Update competitors
			competitor1.update();
			competitor2.update();

			//Check for collisions
			Directory.collisionManager.update();

			//remove every game object in toRemove
			for(GameObject obj : toRemove){
				objects.remove(obj);
				//if obj is a destructable
				if(obj instanceof Entity){
					//Remove from destructables
					targetables.remove((Entity)obj);
				}
			}
			toRemove.clear();



			//Get copyList
			ArrayList<GameObject> copyList = new ArrayList<GameObject>(toAdd);
			//add every game object in toAdd
			for(GameObject obj : copyList)
			{
				objects.add(obj);
				//if obj is a entity
				if(obj instanceof Entity){
					//Add to entities
					targetables.add((Entity)obj);
				}
			}
			toAdd.removeAll(copyList);

			//Check if the battle is over
			if(isBattleOver()){
				isBattleOver = true;
				
				// if player has won, give gold and increment enemiesDefeated
				if(isPlayerWinner()){
					//Add gold to the player based on loser's stats
					Directory.profile.addGold(competitor2.getTotalHealth() * competitor2.getPower() * competitor2.getDefense());
					Directory.profile.addEnemiesDefeated(1);
				}
				
				displayResults();
			}
		}
	}