summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
11ca89e)
Load modules at runtime, so they do not need to be installed if they
aren't used.
binmode $imgfile;
select $imgfile;
binmode $imgfile;
select $imgfile;
my $ani = GD::Image->new($head->{width}, $head->{height});
my $bg = $ani->colorAllocate(0, 0, 0);
my @plot = (
my $ani = GD::Image->new($head->{width}, $head->{height});
my $bg = $ani->colorAllocate(0, 0, 0);
my @plot = (
-use Games::StarCraft::DB;
+if ($DBGAME or $DBNAME) {
+
+require Games::StarCraft::DB;
my $Db = Games::StarCraft::DB->connect({RaiseError => 1})
or die "No database: $DBI::errstr\n";
my $Db = Games::StarCraft::DB->connect({RaiseError => 1})
or die "No database: $DBI::errstr\n";
sub findaccount ($) {
my ($name) = @_;
my $query = $Db->query(q{
sub findaccount ($) {
my ($name) = @_;
my $query = $Db->query(q{
if ($APMSVG) {
my @seq; # player => time (s) => actions
$seq[$_->[1]][$_->[0] * .042]++ for @$map;
if ($APMSVG) {
my @seq; # player => time (s) => actions
$seq[$_->[1]][$_->[0] * .042]++ for @$map;
}
BEGIN { unshift @INC, '.' }
}
BEGIN { unshift @INC, '.' }
- use SVG::TT::Graph::TimeSeries;
+ require SVG::TT::Graph::TimeSeries;
my $graph = SVG::TT::Graph::TimeSeries->new({
height => 1200,
width => 1600,
my $graph = SVG::TT::Graph::TimeSeries->new({
height => 1200,
width => 1600,