Added coastal defenses sites generator for Iran and China.

This commit is contained in:
Khopa
2021-02-05 00:15:06 +01:00
committed by Simon Clark
parent c5ae872787
commit 6a74c3faeb
23 changed files with 212 additions and 65 deletions

View File

@@ -134,6 +134,8 @@ def load_icons():
ICONS["missile_blue"] = QPixmap("./resources/ui/ground_assets/missile_blue.png")
ICONS["nothreat"] = QPixmap("./resources/ui/ground_assets/nothreat.png")
ICONS["nothreat_blue"] = QPixmap("./resources/ui/ground_assets/nothreat_blue.png")
ICONS["coastal"] = QPixmap("./resources/ui/ground_assets/coastal.png")
ICONS["coastal_blue"] = QPixmap("./resources/ui/ground_assets/coastal_blue.png")
ICONS["Generator"] = QPixmap("./resources/ui/misc/"+get_theme_icons()+"/generator.png")
ICONS["Missile"] = QPixmap("./resources/ui/misc/"+get_theme_icons()+"/missile.png")

View File

@@ -9,7 +9,7 @@ from game import Game
from game.data.building_data import FORTIFICATION_BUILDINGS
from game.db import REWARDS
from game.theater import ControlPoint, TheaterGroundObject
from game.theater.theatergroundobject import MissileSiteGroundObject
from game.theater.theatergroundobject import MissileSiteGroundObject, CoastalSiteGroundObject
from qt_ui.windows.groundobject.QGroundObjectMenu import QGroundObjectMenu
from .QMapObject import QMapObject
from ...displayoptions import DisplayOptions
@@ -77,6 +77,8 @@ class QMapGroundObject(QMapObject):
cat = "ship"
if isinstance(self.ground_object, MissileSiteGroundObject):
cat = "missile"
if isinstance(self.ground_object, CoastalSiteGroundObject):
cat = "coastal"
rect = QRect(option.rect.x() + 2, option.rect.y(),
option.rect.width() - 2, option.rect.height())