sc: indicate buildings by size "B"
authorMischa POSLAWSKY <perl@shiar.org>
Sun, 14 Jun 2015 09:34:48 +0000 (11:34 +0200)
committerMischa POSLAWSKY <perl@shiar.org>
Sun, 14 Jun 2015 09:34:48 +0000 (11:34 +0200)
sc-units-hots.inc.pl
sc.plp

index 022b69c8352e7e9ef7a84767730ed9917694d32a..8ce7d2cd051e2cf3f164e7ccc3ea0f4692018bd1 100644 (file)
@@ -40,7 +40,6 @@ use strict;
        race => 'protoss',
        cat => 'base',
        name => 'Photon Cannon',
        race => 'protoss',
        cat => 'base',
        name => 'Photon Cannon',
-       unit => 0,
        min => 150,
        gas => 0,
        build => 40,
        min => 150,
        gas => 0,
        build => 40,
@@ -50,8 +49,8 @@ use strict;
        shield => 150,
        attr => {
                armored => 1,
        shield => 150,
        attr => {
                armored => 1,
+               structure => 1,
        },
        },
-       structure => 1,
        attack => {
                ground => {
                        damage => 20,
        attack => {
                ground => {
                        damage => 20,
@@ -132,7 +131,6 @@ use strict;
        race => 'protoss',
        cat => 'base',
        name => 'Nexus',
        race => 'protoss',
        cat => 'base',
        name => 'Nexus',
-       unit => 0,
        min => 400,
        gas => 0,
        build => 100,
        min => 400,
        gas => 0,
        build => 100,
@@ -143,8 +141,8 @@ use strict;
        shield => 1000,
        attr => {
                armored => 1,
        shield => 1000,
        attr => {
                armored => 1,
+               structure => 1,
        },
        },
-       structure => 1,
        attack => {
                ground => {
                        damage => 20,
        attack => {
                ground => {
                        damage => 20,
@@ -710,7 +708,6 @@ use strict;
        race => 'terran',
        cat => 'base',
        name => 'Missile Turret',
        race => 'terran',
        cat => 'base',
        name => 'Missile Turret',
-       unit => 0,
        min => 100,
        gas => 0,
        build => 25,
        min => 100,
        gas => 0,
        build => 25,
@@ -721,8 +718,8 @@ use strict;
        attr => {
                armored => 1,
                mech => 1,
        attr => {
                armored => 1,
                mech => 1,
+               structure => 1,
        },
        },
-       structure => 1,
        attack => {
                air => {
                        damage => 12,
        attack => {
                air => {
                        damage => 12,
@@ -748,7 +745,7 @@ use strict;
        cat => 'base',
        name => 'Planetary Fortress',
        base => ['Command Center'],
        cat => 'base',
        name => 'Planetary Fortress',
        base => ['Command Center'],
-       unit => 0,
+       unit => -11,
        min => 150,
        gas => 150,
        build => 50,
        min => 150,
        gas => 150,
        build => 50,
@@ -759,8 +756,8 @@ use strict;
        attr => {
                armored => 1,
                mech => 1,
        attr => {
                armored => 1,
                mech => 1,
+               structure => 1,
        },
        },
-       structure => 1,
        attack => {
                ground => {
                        damage => 40,
        attack => {
                ground => {
                        damage => 40,
@@ -1256,8 +1253,8 @@ use strict;
                        attr => {
                                armored => 1,
                                mech => 1,
                        attr => {
                                armored => 1,
                                mech => 1,
+                               structure => 1,
                        },
                        },
-                       structure => 1,
                        attack => {
                                ground => {
                                        damage => 8,
                        attack => {
                                ground => {
                                        damage => 8,
@@ -1286,8 +1283,8 @@ use strict;
                        attr => {
                                light => 1,
                                mech => 1,
                        attr => {
                                light => 1,
                                mech => 1,
+                               structure => 1,
                        },
                        },
-                       structure => 1,
                        cooldown => 0,
                        attack => {
                                range => 8,
                        cooldown => 0,
                        attack => {
                                range => 8,
@@ -1501,7 +1498,6 @@ use strict;
        race => 'zerg',
        cat => 'creep',
        name => 'Spine Crawler',
        race => 'zerg',
        cat => 'creep',
        name => 'Spine Crawler',
-       unit => 0,
        min => 100,
        gas => 0,
        build => 50,
        min => 100,
        gas => 0,
        build => 50,
@@ -1512,8 +1508,8 @@ use strict;
        attr => {
                armored => 1,
                organic => 1,
        attr => {
                armored => 1,
                organic => 1,
+               structure => 1,
        },
        },
-       structure => 1,
        attack => {
                ground => {
                        damage => 25,
        attack => {
                ground => {
                        damage => 25,
@@ -1532,7 +1528,6 @@ use strict;
        race => 'zerg',
        cat => 'creep',
        name => 'Spore Crawler',
        race => 'zerg',
        cat => 'creep',
        name => 'Spore Crawler',
-       unit => 0,
        min => 75,
        gas => 0,
        build => 30,
        min => 75,
        gas => 0,
        build => 30,
@@ -1543,8 +1538,8 @@ use strict;
        attr => {
                armored => 1,
                organic => 1,
        attr => {
                armored => 1,
                organic => 1,
+               structure => 1,
        },
        },
-       structure => 1,
        attack => {
                air => {
                        damage => 15,
        attack => {
                air => {
                        damage => 15,
@@ -1764,7 +1759,6 @@ use strict;
        race => 'zerg',
        cat => 'lair',
        name => 'Nydus Worm',
        race => 'zerg',
        cat => 'lair',
        name => 'Nydus Worm',
-       unit => 0,
        min => 100,
        gas => 100,
        build => 20,
        min => 100,
        gas => 100,
        build => 20,
@@ -1775,8 +1769,8 @@ use strict;
        attr => {
                armored => 1,
                organic => 1,
        attr => {
                armored => 1,
                organic => 1,
+               structure => 1,
        },
        },
-       structure => 1,
        speed => 0,
        sight => 10,
 },
        speed => 0,
        sight => 10,
 },
diff --git a/sc.plp b/sc.plp
index 59ef95cfe84d9d4f4470d0ff9b17b06bc8578e50..88459de209db7ebfea664984b1d962dec2c8a44e 100644 (file)
--- a/sc.plp
+++ b/sc.plp
@@ -180,7 +180,10 @@ sub showval {
                local $_ = $row;
                $_->{hp} += $_->{shield} if $_->{shield};
                my $suitchar = '';
                local $_ = $row;
                $_->{hp} += $_->{shield} if $_->{shield};
                my $suitchar = '';
-               if ($_->{suit}) {
+               if ($_->{attr}->{structure}) {
+                       $suitchar = 'b';
+               }
+               elsif ($_->{suit}) {
                        $suitchar = [qw/? s m l/]->[$_->{suit}];
                }
                elsif ($_->{cargo} > 0) {
                        $suitchar = [qw/? s m l/]->[$_->{suit}];
                }
                elsif ($_->{cargo} > 0) {