doubledmax=32*15;// tiles of length 32 : so 15 tiles
intnewvictim=-1;
for(inti=0;i<entityList.size();i++){
Characteract_entity=entityList.get(i);
if(act_entity.getFaction()==faction||faction==2){// if act_entity is in the asked faction, or if faction = 2 that means that we don't care of the faction