# HG changeset patch # User "Rex Tsai " # Date 1235377475 -28800 # Node ID 4bea7db828ebaad9c70e8cfbc9a123a5b3e71431 # Parent 58351fccf61998a10b51fb4191c410f35747b3e8 fixed scanner diff -r 58351fccf619 -r 4bea7db828eb Ikariam.pm --- a/Ikariam.pm Mon Feb 23 16:24:22 2009 +0800 +++ b/Ikariam.pm Mon Feb 23 16:24:35 2009 +0800 @@ -242,18 +242,19 @@ my $nodes = jsonToObj($c); my @islands; - print $nodes->{'data'}; +# print Dumper($nodes->{'data'}); foreach my $x (keys %{$nodes->{'data'}}) { foreach my $y (keys(%{$nodes->{data}->{$x}})) { my %island; - $island{id} = $nodes->{data}->{$x}->{$y}[0]; $island{x} = $x; $island{y} = $y; + + $island{id} = $nodes->{data}->{$x}->{$y}[0]; $island{name} = $nodes->{data}->{$x}->{$y}[1]; + $island{tradegood} = $nodes->{data}->{$x}->{$y}[2]; + $island{wonder} = $nodes->{data}->{$x}->{$y}[3]; + $island{people} = $nodes->{data}->{$x}->{$y}[6]; -# $island{tradegood} = $4; -# $island{wonder} = $5; -# $island{people} = $8; push @islands, \%island; } }