]> ruin.nu Git - NDIRC.git/commitdiff
Switched intel commands to intel group
authorMichael Andreen <harv@ruin.nu>
Thu, 3 Jul 2008 10:53:29 +0000 (12:53 +0200)
committerMichael Andreen <harv@ruin.nu>
Thu, 3 Jul 2008 10:53:29 +0000 (12:53 +0200)
Intel.pm
PA.pm

index bc9a92559285d2544287808422be6b607dc8487e..18ea15f16fc2218cf8ca2225c3a9da28e58bf37c 100644 (file)
--- a/Intel.pm
+++ b/Intel.pm
@@ -63,7 +63,7 @@ sub setNick {
                $ND::server->command("notice $ND::nick Usage: .$command X:Y:Z nick");
                return;
        }
-       if (my $user = officer){
+       if (my $user = intel){
                my $findid = $ND::DBH->prepare_cached(q{SELECT nick, id FROM planets
                        WHERE id = planetid(?,?,?,tick())});
                my ($oldnick,$id) = $ND::DBH->selectrow_array($findid,undef,$x,$y,$z);
@@ -93,7 +93,7 @@ sub setAlly {
                $ND::server->command("notice $ND::nick Usage: .$command X:Y:Z ally | | % can be used for wildcards \%-crew\% will match [F-Crew]");
                return;
        }
-       if (my $user = officer){
+       if (my $user = intel){
                my $aid;
                if ($ally ne 'unknown'){
                        ($aid,$ally) = $ND::DBH->selectrow_array("SELECT id,name FROM alliances WHERE name ILIKE ?",undef,$ally);
@@ -135,7 +135,7 @@ sub setChannel {
                $ND::server->command("notice $ND::nick Usage: .$command X:Y:Z channel");
                return;
        }
-       if (my $user = officer()){
+       if (my $user = intel){
                my $findid = $ND::DBH->prepare_cached(q{SELECT id,channel FROM current_planet_stats 
                                WHERE x = ? AND y = ? and z = ?});
                my ($id,$c) = $ND::DBH->selectrow_array($findid,undef,$x,$y,$z);
diff --git a/PA.pm b/PA.pm
index 21183bcc16cfacf6043b022b041a18dfc99fcdab..afc5b05861801cfec845aeb7060d4027f26c2368 100644 (file)
--- a/PA.pm
+++ b/PA.pm
@@ -38,7 +38,7 @@ sub checkPlanet {
                $x = $1;
                $y = $2;
                $z = $3;
-       }elsif ((officer() || ia()) && defined $msg){
+       }elsif ((officer() || ia() || intel()) && defined $msg){
                $nick = $msg;
        }else{
                $ND::server->command("notice $ND::nick usage .p X:Y:Z".(officer() || ia() ? ' or .p nick' : ''));
@@ -54,7 +54,7 @@ sub checkPlanet {
                        $planet->{$_} = valuecolor(1,$planet->{$_});
                }
                my $ally = "";
-               if (officer() || ia() || dc()){
+               if (officer() || ia() || dc() | intel()){
                        $ally = "Alliance=$planet->{alliance} ($planet->{relationship}), Nick=$planet->{nick} ($planet->{planet_status}), Channel: $planet->{channel}, Hostile Count: $planet->{hit_us},";
                }
                $ND::server->command("notice $ND::nick $planet->{coords} $planet->{ruler} OF $planet->{planet},$ally Race=$planet->{race}, Score=$planet->{score} ($planet->{scorerank}), Size=$planet->{size} ($planet->{sizerank}), Value=$planet->{value} ($planet->{valuerank}), XP=$planet->{xp} ($planet->{xprank})");