Mercurial > eagle-eye
diff warfare.pl @ 260:a5bd0050dd12
fixed the wrong syntax.
author | "Rex Tsai <chihchun@kalug.linux.org.tw>" |
---|---|
date | Wed, 19 Nov 2008 12:23:30 +0800 |
parents | a4e52feec5a5 |
children | 2488d31240b7 |
line wrap: on
line diff
--- a/warfare.pl Wed Nov 19 01:35:47 2008 +0800 +++ b/warfare.pl Wed Nov 19 12:23:30 2008 +0800 @@ -88,19 +88,19 @@ # we don't fight with members in same ally. next if($sheep->allyId == $user->allyId); - # we fight for island which ownes differnet trade goods. - next if($island->tradegood == $tradegood) unless ($city->status eq 'i'); - # Ignore the user in vacation which we can not attack. next if($city->status eq 'v'); unless ($city->status eq 'i') { + # we fight for island which ownes differnet trade goods. + next CITY if($island->tradegood == $tradegood); + unless (!defined($sheep->allyId) || $sheep->allyId == 0) { 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($ally->score == 0); - next if($targetAlly->score > $ally->score); - next if(defined($ally) && $ally->members > 12); + next CITY if($ally->score == 0); + next CITY if($targetAlly->score > $ally->score); + next CITY if(defined($ally) && $ally->members > 12); } }