H7Town¶
Class in MMH7Game · MMH7Game.H7Town · native, perobjectconfig
Object › Actor › SkeletalMeshActor › SkeletalMeshCinematicActor › SkeletalMeshActorMAT › H7EditorMapObject › H7AdventureObject › H7VisitableSite › H7AreaOfControlSite › H7AreaOfControlSiteLord › H7Town
Implements: H7ITooltipable, H7ILocaParamizable
Subclasses: H7RandomTown
Using it from Lua
Properties¶
| Name | Type | Notes |
|---|---|---|
mAiDone | bool | no declaration: type is approximate |
mAiEnableDevelopTown | bool | no declaration: type is approximate |
mAiEnableHireHeroes | bool | no declaration: type is approximate |
mAiEnableRecruitment | bool | no declaration: type is approximate |
mAiEnableTrade | bool | no declaration: type is approximate |
mAiInHibernation | bool | no declaration: type is approximate |
mAiIsCrusadeTarget | bool | no declaration: type is approximate |
mAiIsMain | bool | no declaration: type is approximate |
mBestGuardBuilding | Object | no declaration: type is approximate |
mBuildingCostModifier | float | no declaration: type is approximate |
mBuildings | array | no declaration: type is approximate |
mBuildingsBuiltToday | int | no declaration: type is approximate |
mBuildingTemplates | array<H7TownBuildingData> | protected |
mBuildingTreeTemplate | array | no declaration: type is approximate |
mCombatMapName | string | protected |
mCurrentCaravanSources | array | no declaration: type is approximate |
mCurrentCaravanTarget | Object | no declaration: type is approximate |
mCurrentlyDestroyingBuilding | struct | no declaration: type is approximate |
mDwellings | array | no declaration: type is approximate |
mFactionBannerIcon | DynLoadObject | no declaration: type is approximate |
mFactionBGTownHall | DynLoadObject | no declaration: type is approximate |
mFactionGateImage | Object | no declaration: type is approximate |
mFactionTowerImage | DynLoadObject | no declaration: type is approximate |
mFactionTownPortalFrame | DynLoadObject | no declaration: type is approximate |
mFactionTownScreen | DynLoadObject | no declaration: type is approximate |
mFactionWallsImage | DynLoadObject | no declaration: type is approximate |
mFactionWatermark | DynLoadObject | no declaration: type is approximate |
mFortificationsOverridden | bool | no declaration: type is approximate |
mGovernor | H7AdventureHero | protected |
mGuardGrowthEnhancer | Object | no declaration: type is approximate |
mGUIconfig | string | no declaration: type is approximate |
mGuildSpecialisation | byte | no declaration: type is approximate |
mGuildSpecialized | bool | no declaration: type is approximate |
mHasBuilt | bool | no declaration: type is approximate |
mHasDestroyed | bool | no declaration: type is approximate |
mHasForceReapplyAura | int | no declaration: type is approximate |
mIncomeModifier | float | no declaration: type is approximate |
mIncomeResource | Object | no declaration: type is approximate |
mLocalGuardSlots | int | protected |
mMagicGuilds | array | no declaration: type is approximate |
mMaxBuildingsPerDay | int | no declaration: type is approximate |
mPredefinedGovernor | H7AdventureArmy | protected |
mPredefinedMagicGuildSpec | byte | no declaration: type is approximate |
mPredefinedMagicGuildSpells | array | |
mRefundBuffer | array | no declaration: type is approximate |
mRefundHero | interface | no declaration: type is approximate |
mRefundPercentage | int | no declaration: type is approximate |
mReserveMultiplier | float | no declaration: type is approximate |
mSiegeDecorationList | array | no declaration: type is approximate |
mSiegeObstacleGate | DynLoadObject | no declaration: type is approximate |
mSiegeObstacleGateOverride | Object | no declaration: type is approximate |
mSiegeObstacleMoat | DynLoadObject | no declaration: type is approximate |
mSiegeObstacleTower | DynLoadObject | no declaration: type is approximate |
mSiegeObstacleTowerOverride | Object | no declaration: type is approximate |
mSiegeObstacleWall | DynLoadObject | no declaration: type is approximate |
mSiegeObstacleWallOverride | Object | no declaration: type is approximate |
mTearOfAshaRewards | array | no declaration: type is approximate |
mTier1FX | Object | no declaration: type is approximate |
mTier1Mesh | Object | no declaration: type is approximate |
mTier2FX | Object | no declaration: type is approximate |
mTier2Mesh | Object | no declaration: type is approximate |
mTier3FX | Object | no declaration: type is approximate |
mTier3Mesh | Object | no declaration: type is approximate |
mTier4FX | Object | no declaration: type is approximate |
mTier4Mesh | Object | no declaration: type is approximate |
mTownCameraProperties | Object | no declaration: type is approximate |
mTownNameIndex | int | no declaration: type is approximate |
Functions¶
| Name | Declaration |
|---|---|
AddCaravanSource | function AddCaravanSource(H7Town Town) |
AddToRefundBuffer | function AddToRefundBuffer(H7ResourceQuantity newEntry) |
AiAutotradeResources | function bool AiAutotradeResources(H7Resource needResource) |
AiCalculateTradeRateFactor | function float AiCalculateTradeRateFactor(bool tradingPostBuff) |
AiDoTrade | function AiDoTrade(string resourceToSell, int amountToSell, string resourceToBuy, int amountToBuy) |
AiGetAmountMarketPlaces | function int AiGetAmountMarketPlaces() |
AiSelectSchool | function AiSelectSchool() |
AlreadyHasSpell | function bool AlreadyHasSpell(H7HeroAbility Spell, array<H7HeroAbility> existing) |
BuildBuilding | function bool BuildBuilding(string buildingID) |
BuildBuildingComplete | function BuildBuildingComplete(string buildingID, optional bool spendResources = true) |
BuildBuildingForced | function bool BuildBuildingForced(string buildingName) |
CanAffordBuilding | function bool CanAffordBuilding(H7TownBuilding Building) |
CanBuildCaravanThisTurn | function CanBuildCaravanThisTurn(bool Value) |
CanRecruitHero | function bool CanRecruitHero(H7EditorArmy armyToRecruit) |
CheckBuildingRequirements | native function bool CheckBuildingRequirements(H7TownBuilding Building) |
ClearCaravanSources | function ClearCaravanSources() |
Conquer | function Conquer(H7AdventureHero conqueror) |
ConsumeTearOfAsha | function bool ConsumeTearOfAsha() |
CouldUpdateAuras | function bool CouldUpdateAuras() |
CreateBuilding | private final function H7TownBuilding CreateBuilding(H7TownBuilding buildingArchetype, optional bool isForced = false) |
DataChanged | event DataChanged(optional string cause) |
DelCombatMapDecoListRef | function DelCombatMapDecoListRef() |
DelCombatMapGateRef | function DelCombatMapGateRef() |
DelCombatMapMoatRef | function DelCombatMapMoatRef() |
DelCombatMapTowerRef | function DelCombatMapTowerRef() |
DelCombatMapWallRef | function DelCombatMapWallRef() |
DeleteRefundBuffer | function DeleteRefundBuffer() |
DelFactionBannerIconRef | function DelFactionBannerIconRef() |
DelFactionBGTownHallRef | function DelFactionBGTownHallRef() |
DelFactionGateImageRef | function DelFactionGateImageRef() |
DelFactionTowerImageRef | function DelFactionTowerImageRef() |
DelFactionTownPortalFrameRef | function DelFactionTownPortalFrameRef() |
DelFactionTownScreenRef | function DelFactionTownScreenRef() |
DelFactionWallsImageRef | function DelFactionWallsImageRef() |
DelFactionWatermarkRef | function DelFactionWatermarkRef() |
DestroyBuilding | function DestroyBuilding(H7TownBuilding Building) |
DestroyBuildingByIndex | protected function DestroyBuildingByIndex(int Index, optional bool simulate) |
DestroyBuildingsOfLevel | event DestroyBuildingsOfLevel(int Level) |
DestroyBuildingsOfLevelComplete | function DestroyBuildingsOfLevelComplete(int Level, bool simulate) |
DisableBuilding | function DisableBuilding(H7TownBuilding Building) |
DoSabotage | function array<H7TownDwelling> DoSabotage() |
DumpCurrentState | function DumpCurrentState() |
DumpTownBuildings | function DumpTownBuildings() |
FindBuildingsOfType | native function FindBuildingsOfType(Class comparisonClass, out array<H7TownBuilding> resultList) |
GetAddBoniOnStatByID | native function float GetAddBoniOnStatByID(H7StructsAndEnumsNative.EStat desiredStat) |
GetAiEnableDevelopTown | function bool GetAiEnableDevelopTown() |
GetAiEnableHireHeroes | function bool GetAiEnableHireHeroes() |
GetAiEnableRecruitment | function bool GetAiEnableRecruitment() |
GetAiEnableTrade | function bool GetAiEnableTrade() |
GetAiHibernationState | function bool GetAiHibernationState() |
GetAiIsCrusadeTarget | function bool GetAiIsCrusadeTarget() |
GetAiIsMain | function bool GetAiIsMain() |
GetArchetype | function H7Town GetArchetype() |
GetAvailableSpells | function array<H7HeroAbility> GetAvailableSpells() |
GetBaseBuilding | function H7TownBuilding GetBaseBuilding(H7TownBuilding upgradeBuilding) |
GetBaseStatByID | native function float GetBaseStatByID(H7StructsAndEnumsNative.EStat desiredStat) |
GetBestAssetForSlot | function H7TownAsset GetBestAssetForSlot(H7TownBuilding Building, H7TownAsset Asset) |
GetBestBuilding | native function H7TownBuildingData GetBestBuilding(H7TownBuildingData baseBuilding) |
GetBestBuildingByBuilding | function H7TownBuildingData GetBestBuildingByBuilding(H7TownBuilding Building) |
GetBestDwelling | native function H7TownBuildingData GetBestDwelling(H7TownBuildingData baseBuilding) |
GetBestImplicitUpgrade | function H7TownBuildingData GetBestImplicitUpgrade(H7TownBuildingData Building) |
GetBuildingByAsset_BROKEN | function H7TownBuilding GetBuildingByAsset_BROKEN(H7TownAsset assetInstance) |
GetBuildingByAssetType | function H7TownBuilding GetBuildingByAssetType(string assetType) |
GetBuildingByPrefabAsset | function H7TownBuilding GetBuildingByPrefabAsset(H7TownAsset prefabAsset) |
GetBuildingByType | function H7TownBuilding GetBuildingByType(Class C) |
GetBuildingCostModifier | function float GetBuildingCostModifier() |
GetBuildingDataByType | function H7TownBuildingData GetBuildingDataByType(Class C) |
GetBuildingLevelByType | function int GetBuildingLevelByType(Class BuildingType) |
GetBuildings | function array<H7TownBuildingData> GetBuildings() |
GetBuildingsByAssetType | function array<H7TownBuilding> GetBuildingsByAssetType(string assetType) |
GetBuildingsByType | function array<H7TownBuildingData> GetBuildingsByType(Class C) |
GetBuildingTemplateByType | function H7TownBuildingData GetBuildingTemplateByType(Class C) |
GetBuildingTemplatesByType | function array<H7TownBuildingData> GetBuildingTemplatesByType(Class C) |
GetBuildingTree | native function array<H7TownBuildingData> GetBuildingTree() |
GetBuildingWarfare | function H7TownUtilityUnitDwelling GetBuildingWarfare(bool attackHybrid) |
GetCapitol | native function H7TownHall GetCapitol() |
GetCombatMapDecoList | function array<H7EditorSiegeDecoration> GetCombatMapDecoList() |
GetCombatMapGate | function H7CombatMapGate GetCombatMapGate() |
GetCombatMapMoat | function H7CombatMapMoat GetCombatMapMoat() |
GetCombatMapName | function string GetCombatMapName() |
GetCombatMapTower | function H7CombatMapTower GetCombatMapTower() |
GetCombatMapWall | function H7CombatMapWall GetCombatMapWall() |
GetCreaturePool | function array<H7DwellingCreatureData> GetCreaturePool() |
GetCurrencyIncome | native function int GetCurrencyIncome() |
GetCurrentCaravanSources | function array<H7Town> GetCurrentCaravanSources() |
GetCurrentCaravanTarget | function H7Town GetCurrentCaravanTarget() |
GetDwellings | native function GetDwellings(out array<H7TownBuildingData> Dwellings) |
GetEntityType | native function H7StructsAndEnumsNative.EUnitType GetEntityType() |
GetFactionBannerIconPath | function string GetFactionBannerIconPath() |
GetFactionBGTownHallPath | function string GetFactionBGTownHallPath() |
GetFactionPortalFramePath | function string GetFactionPortalFramePath() |
GetFactionWatermarkPath | function string GetFactionWatermarkPath() |
GetGateIconPath | function string GetGateIconPath() |
GetGenericName | protected function string GetGenericName() |
GetGovernor | function H7AdventureHero GetGovernor() |
GetGrowthBonus | function int GetGrowthBonus(H7Creature Creature, optional out array<H7TooltipModifierInfo> Modifiers, optional H7TownDwelling townDwelling) |
GetGrowthBuildings | function array<H7TownBuildingData> GetGrowthBuildings() |
GetGuardCapacityFor | function int GetGuardCapacityFor(H7DwellingCreatureData Data) |
GetGuardGrowthBuildings | native function array<H7TownGuardGrowthEnhancer> GetGuardGrowthBuildings() |
GetGuardIncomeFor | function int GetGuardIncomeFor(H7DwellingCreatureData Data) |
GetGUIconfig | function string GetGUIconfig() |
GetHighestBuildingLevel | native function int GetHighestBuildingLevel() |
GetIconPath | function string GetIconPath() |
GetIncomeByResource | native function int GetIncomeByResource(H7Resource resourceType) |
GetIncomeIcon | function string GetIncomeIcon() |
GetIncomeResource | function H7Resource GetIncomeResource() |
GetInfoIconPath | function string GetInfoIconPath(optional out string ToolTip) |
GetLevel | function int GetLevel() |
GetLocalGuardSlots | function int GetLocalGuardSlots() |
GetMageGuildSpecialisationStatus | function bool GetMageGuildSpecialisationStatus() |
GetModifiedStatByID | native function float GetModifiedStatByID(H7StructsAndEnumsNative.EStat desiredStat) |
GetModifiersByID | native function GetModifiersByID(out array<H7MeModifiesStat> outStats, H7StructsAndEnumsNative.EStat desiredStat, optional H7StructsAndEnumsNative.EOperationType checkForOperation1 = 255, optional H7StructsAndEnumsNative.EOperationType checkForOperation2 = 255, optional bool nextRound) |
GetMultiBoniOnStatByID | native function float GetMultiBoniOnStatByID(H7StructsAndEnumsNative.EStat desiredStat) |
GetName | function string GetName() |
GetPredefinedMagicGuildSpecialisation | function H7StructsAndEnumsNative.EAbilitySchool GetPredefinedMagicGuildSpecialisation() |
GetRefundBuffer | function array<H7ResourceQuantity> GetRefundBuffer() |
GetRefundHero | function H7ICaster GetRefundHero() |
GetRefundPercentage | function int GetRefundPercentage() |
GetRolledTearOfAshaRewards | function array |
GetSpecialisation | function H7StructsAndEnumsNative.EAbilitySchool GetSpecialisation() |
GetTooltipData | function H7TooltipData GetTooltipData(optional bool extendedVersion) |
GetTowerIconPath | function string GetTowerIconPath() |
GetTownCameraProperties | function H7CameraProperties GetTownCameraProperties() |
GetTownScreen | function Prefab GetTownScreen() |
GetUpgradeBase | function H7TownBuilding GetUpgradeBase(H7TownBuilding Building, optional bool useExistingBuildingList = false) |
GetUpgradeFor | function H7TownBuilding GetUpgradeFor(H7TownBuilding Building, optional bool useExistingBuildingList = false) |
GetWallsIconPath | function string GetWallsIconPath() |
GUIAddListener | function GUIAddListener(GFxObject Data, optional H7StructsAndEnums.H7ListenFocus Focus) |
GUIWriteInto | function GUIWriteInto(GFxObject Data, optional H7StructsAndEnums.H7ListenFocus Focus, optional H7GFxUIContainer flashFactory) |
HasBuiltToday | function bool HasBuiltToday() |
HasChampionDwellingBuilt | function bool HasChampionDwellingBuilt() |
HasDestroyedToday | function bool HasDestroyedToday() |
HasOutSideDwellings | function bool HasOutSideDwellings() |
HasOutSideDwellingsBelongingToOwner | function bool HasOutSideDwellingsBelongingToOwner() |
HasRequiredDwelling | function bool HasRequiredDwelling(H7Creature upgradedCreature) |
HasResourcesToBuild | function bool HasResourcesToBuild() |
Hide | function Hide() |
InitAdventureObject | event InitAdventureObject() |
InitMagicGuilds | function InitMagicGuilds() |
IsAiDone | function bool IsAiDone() |
IsAvailable | native function bool IsAvailable(H7TownBuilding Building) |
IsBuildingBuilt | native function bool IsBuildingBuilt(H7TownBuilding Building, optional bool returnTrueIfUpgradeIsBuilt = false, optional bool returnTrueIfAlternateIsBuilt = false, optional out H7TownBuildingData Data) |
IsBuildingBuiltByClass | function bool IsBuildingBuiltByClass(Class dasClass) |
IsBuildingBuiltByName | function bool IsBuildingBuiltByName(string buildingName, optional out H7TownBuildingData Data) |
IsBuildingEqual | native function bool IsBuildingEqual(H7TownBuilding building1, H7TownBuilding building2) |
IsCapitolBuilt | native function bool IsCapitolBuilt() |
IsDwellingBuilt | native function bool IsDwellingBuilt(H7TownBuilding Building, optional bool returnTrueIfUpgradeIsBuilt = false, optional bool returnTrueIfAlternateIsBuilt = false, optional out H7TownBuildingData Data) |
IsFullyBuilt | function bool IsFullyBuilt() |
IsHavenTown | function bool IsHavenTown() |
IsOnlyTownHallBuilt | function bool IsOnlyTownHallBuilt() |
IsTownPortalBuilt | native function bool IsTownPortalBuilt() |
LearnSpells | function LearnSpells(H7AdventureHero Hero) |
LoadTownAssets | function LoadTownAssets(optional bool delayed = false) |
ModifyPlayerIncome | function ModifyPlayerIncome(bool addIncome) |
MulBuildingCostModifier | function MulBuildingCostModifier(float Modifier) |
NotifyLearnSpells | native function NotifyLearnSpells(H7AdventureHero Hero) |
OnBeginDay | event OnBeginDay() |
OnDoubleClick | function OnDoubleClick() |
OnLeave | function OnLeave() |
OnRightClick | function OnRightClick() |
OnVisit | function OnVisit(out H7AdventureHero Hero) |
OpenTownScreenForMe | function OpenTownScreenForMe() |
PostSerialize | event PostSerialize() |
ProducesTier | native function bool ProducesTier(H7StructsAndEnumsNative.ECreatureTier Tier) |
ProducesUnit | native function bool ProducesUnit(H7Creature Creature) |
ProduceUnits | function ProduceUnits() |
RecruitHero | function bool RecruitHero(int heroId) |
RecruitHeroComplete | function bool RecruitHeroComplete(int heroId) |
RefundBuildingCost | function RefundBuildingCost(H7TownBuilding Building, int percentage, bool isSimulated) |
RequestCreateNewCaravan | function RequestCreateNewCaravan() |
Reveal | function Reveal() |
RollTearOfAshaRewards | function RollTearOfAshaRewards() |
SetAiDone | function SetAiDone(bool Done) |
SetAiEnableDevelopTown | function SetAiEnableDevelopTown(bool State) |
SetAiEnableHireHeroes | function SetAiEnableHireHeroes(bool State) |
SetAiEnableRecruitment | function SetAiEnableRecruitment(bool State) |
SetAiEnableTrade | function SetAiEnableTrade(bool State) |
SetAiHibernationState | function SetAiHibernationState(bool State) |
SetAiIsCrusadeTarget | function SetAiIsCrusadeTarget(bool State) |
SetAiIsMain | function SetAiIsMain(bool State) |
SetBuiltToday | function SetBuiltToday(bool bu) |
SetCurrentCaravanTarget | function SetCurrentCaravanTarget(H7Town Town) |
SetDestroyedToday | function SetDestroyedToday(bool boool) |
SetFortificationOverride | function SetFortificationOverride(H7CombatMapWall Wall, H7CombatMapGate gate, H7CombatMapTower tower) |
SetGovernor | function SetGovernor(H7AdventureHero governor) |
SetGovernorComplete | function SetGovernorComplete(H7AdventureHero governor) |
SetGUIconfig | function SetGUIconfig(string val) |
SetMageGuildSpecialisationStatus | function SetMageGuildSpecialisationStatus(bool Value) |
SetMaxBuildingsPerDay | function SetMaxBuildingsPerDay(int Amount) |
SetRefundHero | function SetRefundHero(H7ICaster Hero) |
SetReserveMultiplier | event SetReserveMultiplier(float M) |
SetSiteOwner | function SetSiteOwner(H7StructsAndEnumsNative.EPlayerNumber NewOwner, optional bool showPopup = true) |
SetSpecialisation | function SetSpecialisation(H7StructsAndEnumsNative.EAbilitySchool school) |
SwitchGUICoords | function SwitchGUICoords(H7TownBuilding From, H7TownBuilding to) |
TriggerEvents | native function TriggerEvents(H7StructsAndEnumsNative.ETrigger triggerEvent, bool forecast, optional H7EventContainerStruct container) |
UnLoadTownAssets | function UnLoadTownAssets() |
UpdateGovernorAuras | function UpdateGovernorAuras() |
UpdateLocalGuardGUI | function UpdateLocalGuardGUI() |
UpdateMagicGuildMessage | function UpdateMagicGuildMessage() |
UpdateMeshes | native function UpdateMeshes() |
UpdateTownMesh | function UpdateTownMesh() |
Default values¶
mAiEnableDevelopTown=true
mAiEnableRecruitment=true
mAiEnableTrade=true
mAiEnableHireHeroes=true
mAiIsMain=true
mReserveMultiplier=1.0000000
mPredefinedMagicGuildSpec=EAbilitySchool.ABILITY_SCHOOL_NONE
mGuildSpecialisation=EAbilitySchool.ABILITY_SCHOOL_NONE
mBuildingCostModifier=1.0000000
mTownNameIndex=-1
mIncomeResource=H7Resource'H7Resources.ResourceTypes.A_Resource_Gold'