X-Git-Url: http://git.shiar.nl/sheet.git/blobdiff_plain/12cb206ab5a8d8a37c78e98fb627edc388e6c1c9..7daf512d5b78e196e4b3ada31ae8c5c9705456d7:/sc.plp diff --git a/sc.plp b/sc.plp index 237ba71..2b8112d 100644 --- a/sc.plp +++ b/sc.plp @@ -1,5 +1,5 @@ <(common.inc.plp)><: -use List::Util qw(max); +use List::Util qw(max sum); my %scver = ( id => 'bw', @@ -47,7 +47,12 @@ die "Cannot open unit data: $_\n" for $@ || $! || (); my $patch = shift @{$units} or die "Cannot open unit data: metadata not found\n"; -print "
Unit properties as seen or measured in $scver{name}\n$patch.\n
\n\n"; +print "Unit properties as seen or measured in $scver{name}\n$patch.\n"; +print "Also see the $_ table.\n" for join(', ', + ('StarCraft 2: HotS') x ($scver{major} < 2), + ('original SC: Brood War') x ($scver{major} > 1), +); +print "
\n\n"; sub addupgrade { my ($ref, $increase) = @_; @@ -70,10 +75,10 @@ for my $unit (@{$units}) { } sub coltoggle { - my ($name, $id) = @_; + my ($name, $id, $nolink) = @_; return sprintf( (defined $get{order} ? $get{order} eq $id : !$id) ? '%2$s â¼' - : '%s', + : $nolink ? '%2$s' : '%s', $id && "order=$id", $name ); } @@ -89,7 +94,7 @@ sub coltoggle {