# HG changeset patch # User "Rex Tsai " # Date 1226042303 -28800 # Node ID 64549ddddf4adb19b1c7102f8c1110797347a6c6 # Parent 937fc672df5606a4307c3cd2740bceee01f3d689 count by ally score diff -r 937fc672df56 -r 64549ddddf4a sheep.pl --- a/sheep.pl Fri Nov 07 15:01:11 2008 +0800 +++ b/sheep.pl Fri Nov 07 15:18:23 2008 +0800 @@ -49,7 +49,6 @@ # avoid duplicate next if($sheep->id == $s); $s = $sheep->id; - foreach my $c ($sheep->cities) { my $line = ""; # Ignore 假期模式 diff -r 937fc672df56 -r 64549ddddf4a warfare.pl --- a/warfare.pl Fri Nov 07 15:01:11 2008 +0800 +++ b/warfare.pl Fri Nov 07 15:18:23 2008 +0800 @@ -94,10 +94,11 @@ next if($city->status eq 'v'); unless ($city->status eq 'i') { unless (!defined($sheep->allyId) || $sheep->allyId == 0) { - my $ally = Ikariam::Ally->retrieve($sheep->allyId); - # Ignore the ally which have more then 10 members. + my $ally = Ikariam::Ally->retrieve($user->allyId); + my $targetAlly = Ikariam::Ally->retrieve($sheep->allyId); # We don't want to piss off the big team. - next if(defined($ally) && $ally->members > 10); + next if($targetAlly->score > $ally->score); + # next if(defined($ally) && $ally->members > 10); } }