public void attack(ArrayList<Mob> mobs){
		if (attackTime >= attackSpeed){
			attackTime = 0;
			for (int i = 0; i < mobs.size(); i++){
				Mob mob = mobs.get(i);
				if (hitBox.intersects(mob)){
					mob.takeDamage(this);
					if (mob.isDead()){
						int mlvl = mob.getMobStat().getLevel();
						mobs.remove(i);
						info.changeXp(mlvl * 60);
						Random r = new Random();
						int k = r.nextInt(mlvl * 5);
						log.writeToLog("Received " + k + " gold and " + mlvl*60 + " experience.", Color.yellow);
						info.changeGold(k);
					}
				}
			}
		}
	}