--- common/unit.c.orig Sun Aug 13 22:27:47 2000 +++ common/unit.c Sun Aug 13 22:30:30 2000 @@ -52,7 +52,8 @@ "OneAttack", "Pikemen", "Horse", "IgWall", "FieldUnit", "AEGIS", "Fighter", "Marines", "Partial_Invis", "Settlers", "Diplomat", "Trireme", "Nuclear", "Spy", "Transform", "Paratroopers", - "Airbase", "Cities", "IgTired", "Missile_Carrier", "No_Land_Attack" + "Airbase", "Cities", "IgTired", "Missile_Carrier", "No_Land_Attack", + "Bomber" }; static char *role_names[] = { "FirstBuild", "Explorer", "Hut", "HutTech", "Partisan", @@ -982,7 +983,7 @@ int pspresent; int psworking; pspresent = get_tile_infrastructure_set(ptile); - if (pspresent && is_ground_unit(punit)) { + if (pspresent && (is_ground_unit(punit) || is_bomber_unit(punit))) { psworking = get_unit_tile_pillage_set(punit->x, punit->y); if (target == S_NO_SPECIAL) return ((pspresent & (~psworking)) != 0); @@ -1517,4 +1518,13 @@ airall += misonly; return airall; +} + +/************************************************************************** +Returns true if unit is a bomber. +Used to determine if unit is able to pillage from the air. +**************************************************************************/ +int is_bomber_unit(struct unit *punit) +{ + return (unit_flag(punit->type, F_BOMBER)); } --- common/unit.h.orig Sun Aug 13 22:30:36 2000 +++ common/unit.h Sun Aug 13 22:31:44 2000 @@ -168,6 +168,7 @@ F_IGTIRED, /* Ignore tired negative bonus when attacking */ F_MISSILE_CARRIER, /* Like F_CARRIER, but missiles only (Submarine) */ F_NO_LAND_ATTACK, /* Cannot attack vs land squares (Submarine) */ + F_BOMBER, /* Can pillage from the air */ F_LAST }; @@ -297,6 +298,7 @@ int is_hiding_unit(struct unit *punit); int is_water_unit(Unit_Type_id id); int is_sailing_unit(struct unit *punit); +int is_bomber_unit(struct unit *punit); int is_air_unit(struct unit *punit); int is_air_unittype(Unit_Type_id id); int is_heli_unit(struct unit *punit); --- data/default/units.ruleset.orig Sun Aug 13 22:36:51 2000 +++ data/default/units.ruleset Sun Aug 13 22:35:11 2000 @@ -780,7 +780,7 @@ uk_shield = 1 uk_food = 0 uk_gold = 0 -flags = "FieldUnit", "OneAttack" +flags = "FieldUnit", "OneAttack", "Bomber" roles = "" [unit_helicopter] @@ -859,7 +859,7 @@ uk_shield = 1 uk_food = 0 uk_gold = 0 -flags = "FieldUnit", "OneAttack" +flags = "FieldUnit", "OneAttack", "Bomber" roles = "" helptext = _("\ An improved Bomber, with improved attack and a higher movement\ --- data/helpdata.txt.orig Sun Aug 13 22:37:18 2000 +++ data/helpdata.txt Sun Aug 13 22:38:14 2000 @@ -1083,11 +1083,11 @@ [help_pillaging] name = _(" Pillaging") text = _("\ -All ground units have the ability to destroy terrain alterations, \ -by pillaging. Pillaging removes 1 terrain alteration per turn per \ -unit. Depending upon server settings, you may be given a choice \ -of which terrain alteration to pillage, or they will be pillaged \ -in the following order:\ +All ground units and bombers have the ability to destroy terrain \ +alterations, by pillaging. Pillaging removes 1 terrain alteration \ +per turn per unit. Depending upon server settings, you may be given \ +a choice of which terrain alteration to pillage, or they will be \ +pillaged in the following order:\ "), _("\ - farmland\n\ - irrigation\n\ --- client/helpdata.c.orig Sun Aug 13 22:32:20 2000 +++ client/helpdata.c Sun Aug 13 22:34:08 2000 @@ -693,6 +693,10 @@ sprintf(buf+strlen(buf), _("* Counts as 'mounted' against certain defenders.\n")); } + if (unit_flag(i, F_BOMBER)) { + sprintf(buf+strlen(buf), _("* A bomber unit (can pillage terrain" + " alterations from the air).\n")); + } if (unit_flag(i, F_MISSILE)) { sprintf(buf+strlen(buf), _("* A missile unit: gets used up in making an attack.\n"));