Module twdll.world

Campaign world singleton and world-level modifiers for Total War: Attila.

Functions

GetMemoryAddress () Returns the memory address of the WORLD singleton as a hexadecimal string.
GetFactionCount () Gets the number of factions in the current campaign.
GetMaxUnitsInArmy () Gets the maximum number of units allowed in an army.
SetMaxUnitsInArmy (val) Sets the maximum number of units allowed in an army.
GetMaxUnitsInNavy () Gets the maximum number of units allowed in a navy.
SetMaxUnitsInNavy (val) Sets the maximum number of units allowed in a navy.
SetReinforcementCap (max_units) Sets the reinforcement cap (max units per army in battle) for battles started after the call.
GetReinforcementCap () Returns the currently applied reinforcement cap, or nil if the game default is in effect.


Functions

GetMemoryAddress ()
Returns the memory address of the WORLD singleton as a hexadecimal string.

Returns:

    string memory address (e.g. "0x12345678"), or nil if not yet initialised
GetFactionCount ()
Gets the number of factions in the current campaign.

Returns:

    integer number of factions, or nil if not yet initialised
GetMaxUnitsInArmy ()
Gets the maximum number of units allowed in an army.

Returns:

    integer maximum unit count
SetMaxUnitsInArmy (val)
Sets the maximum number of units allowed in an army.

Parameters:

  • val integer maximum unit count
GetMaxUnitsInNavy ()
Gets the maximum number of units allowed in a navy.

Returns:

    integer maximum unit count
SetMaxUnitsInNavy (val)
Sets the maximum number of units allowed in a navy.

Parameters:

  • val integer maximum unit count
SetReinforcementCap (max_units)
Sets the reinforcement cap (max units per army in battle) for battles started after the call. Pass -1 to restore the game default (disable the override). Any value >= 0 is applied as-is.

Parameters:

  • max_units integer new cap value, or -1 to restore the default
GetReinforcementCap ()
Returns the currently applied reinforcement cap, or nil if the game default is in effect.

Returns:

    integer current cap value
generated by LDoc 1.5.0