Mercurial > eagle-eye
diff ally.pl @ 174:0cfc7a19a4d2
branch merged
author | "Rex Tsai <chihchun@kalug.linux.org.tw>" |
---|---|
date | Sun, 02 Nov 2008 04:12:23 +0800 |
parents | a60cf4d1a6dd |
children | dd3d76f43999 |
line wrap: on
line diff
--- a/ally.pl Sun Nov 02 04:12:00 2008 +0800 +++ b/ally.pl Sun Nov 02 04:12:23 2008 +0800 @@ -59,16 +59,16 @@ } </style></head><body><table border=1>"); -foreach my $x ($x1..$x2) +foreach my $y($y1..$y2) { print(OUT "<tr>"); - foreach my $y($y1..$y2) + foreach my $x ($x1..$x2) { # printf("<div stlye='float:left; background-color: black; padding: 0; Display:inline;'>o</div>"); if(defined($maps{$x}{$y}{'density'})) { my $c = 255 - (15 * $maps{$x}{$y}{'density'}); - printf(OUT "<td style=\"background-color: rgb(255,%d,%d);\"><a href=\"http://s2.ikariam.tw/index.php?view=island&id=%d\" title=\"[%d,%d] (%d)\">[%d,%d]</a></td>", - $c, $c, $maps{$x}{$y}{'id'}, $x, $y, $maps{$x}{$y}{'density'}, $x, $y); + printf(OUT "<td style=\"background-color: rgb(255,%d,%d);\"><a href=\"http://%s/index.php?view=island&id=%d\" title=\"[%d,%d] (%d)\">[%d,%d]</a></td>", + $c, $c, $::server, $maps{$x}{$y}{'id'}, $x, $y, $maps{$x}{$y}{'density'}, $x, $y); } else { printf(OUT "<td style=\"background-color: rgb(255,255,255);\">[%d,%d]</td>", $x, $y); }