# HG changeset patch # User "Rex Tsai " # Date 1225704051 -28800 # Node ID d9f17bcbf1f127ca821d6b36b2c9fda0b80407af # Parent 95d47d69c20250e2a95b6a35795d6e009986ac1a we keep 10 transporters for prize diff -r 95d47d69c202 -r d9f17bcbf1f1 Ikariam.pm --- a/Ikariam.pm Mon Nov 03 17:02:07 2008 +0800 +++ b/Ikariam.pm Mon Nov 03 17:20:51 2008 +0800 @@ -749,7 +749,7 @@ my %report; $report{id} = $combatId; - my $c = $extractor->{doc}->toString(1); + my $c = $extractor->{doc}->toString(0); # FIXME 城鎮 6 級)的城牆( 2 級)為防禦部隊增加了 7% 的防禦力。 while($c =~ /城鎮\s+(\d+)/gs) { @@ -1049,7 +1049,6 @@ my $cost = 0; foreach(keys(%{$cities->{$cityId}->{army}})) { - # printf("%s %d = %d\n", $_, $cities->{$cityId}->{army}->{$_}, $cities->{$cityId}->{army}->{$_} * $troops->{$_}->{u}); $cost += $cities->{$cityId}->{army}->{$_} * $troops->{$_}->{u}; } return $cost; diff -r 95d47d69c202 -r d9f17bcbf1f1 warfare.pl --- a/warfare.pl Mon Nov 03 17:02:07 2008 +0800 +++ b/warfare.pl Mon Nov 03 17:20:51 2008 +0800 @@ -50,7 +50,8 @@ sub is_transporters_available { my ($self, $city) = @_; - return ($city->{transporters}->{avail} > 0) ? 1 : 0; + # we keep 10 transporters for prize + return ($city->{transporters}->{avail} > 10) ? 1 : 0; } sub is_port_available {