for (Enumeration j = game.getArtilleryAttacks(); j.hasMoreElements();) {
for (Enumeration j = game.getArtilleryAttacks(); !firingAtNewHex && j.hasMoreElements();) {
    private void enqueueIndirectArtilleryAttacks() {        resolveAllButWeaponAttacks();        ArtilleryAttackAction aaa;        for (Enumeration i = game.getActions();i.hasMoreElements();) {            EntityAction ea = (EntityAction) i.nextElement();            final Entity firingEntity = game.getEntity(ea.getEntityId());            if (ea instanceof WeaponAttackAction) {                final WeaponAttackAction waa = (WeaponAttackAction) ea;                WeaponResult wr = preTreatWeaponAttack(waa);                boolean firingAtNewHex = false;                for (Enumeration j = game.getArtilleryAttacks(); j.hasMoreElements();) {                    ArtilleryAttackAction oaaa = (ArtilleryAttackAction) j.nextElement();                    if ( oaaa.getWR().waa.getEntityId() == wr.waa.getEntityId() &&                         !oaaa.getWR().waa.getTarget(game).getPosition().equals(wr.waa.getTarget(game).getPosition())) {                        firingAtNewHex = true;                    }                }                if (firingAtNewHex) {                    clearArtillerySpotters(firingEntity.getId(),waa.getWeaponId());                }                Enumeration spotters = game.getSelectedEntities(new EntitySelector() {                    public int player = firingEntity.getOwnerId();                    public Targetable target = waa.getTarget(game);                    public boolean accept(Entity entity) {                        if ( (player == entity.getOwnerId()) &&                            !((LosEffects.calculateLos(game, entity.getId(), target)).isBlocked()) && entity.isActive()) {                            return true;                        } else {                            return false;                        }                    }                } );                Vector spotterIds = new Vector();                while ( spotters.hasMoreElements() ) {                    Integer id = new Integer                        ( ((Entity) spotters.nextElement() ).getId() );                    spotterIds.addElement( id );                }                aaa = new ArtilleryAttackAction( wr, game,                                                 firingEntity.getOwnerId(),                                                 spotterIds, firingEntity.getPosition());                game.addArtilleryAttack(aaa);            }        }        game.resetActions();    }