]> ruin.nu Git - ndwebbie.git/blobdiff - scripts/scans.pl
proper resources in cov op table
[ndwebbie.git] / scripts / scans.pl
index bc9de5716eb5e0b1b9a4d0db21e7ac4398ea6211..756778ea8c3be35b6a1fb2b89cfbb4c6c068dff2 100755 (executable)
@@ -108,7 +108,7 @@ HTML
                        my $f = $dbh->prepare("UPDATE covop_targets SET metal = ?, crystal = ?, eonium = ? WHERE planet = ?");
                        if ($f->execute($2,$4,$6,$planet) < 1){
                                $f = $dbh->prepare("INSERT INTO covop_targets (planet,metal, crystal, eonium) VALUES(?,?,?,?)");
-                               $f->execute($planet,$4,$5,$6);
+                               $f->execute($planet,$2,$4,$6);
                        }
                }elsif ($type eq 'Jumpgate'){
                        $scantext .= <<HTML
@@ -153,7 +153,7 @@ HTML
 
                                        my $eta = $5 - $t;
                                        my $mission = $4;
-                                       $mission = 'AllyDef' if $eta == 7 && $x != $1;
+                                       $mission = 'AllyDef' if $eta == 6 && $x != $1;
                                        $f->execute($t,$eta,$1,$2,$3,$x,$y,$z,-1,$mission) or print $dbh->errstr;
                                        $class = qq{ class="$mission"};
                                }elsif($news eq 'Incoming' && $text =~ m/We have detected an open jumpgate from (?:[^<]*), located at (\d+):(\d+):(\d+). The fleet will approach our system in tick (\d+) and appears to have roughly (\d+) ships/g){