Skip to main content

hllrcon - Hell Let Loose RCON

Release PyPI Branch Coverage License GitHub contributors GitHub issues GitHub pull requests GitHub stars


hllrcon is an asynchronous Python implementation of the Hell Let Loose and Hell Let Loose: Vietnam RCON protocol.
It allows you to interact with your HLL and HLL:V servers programmatically, supporting modern Python async features and robust error handling.

Features

  • Full async/await support
  • Command execution and response parsing
  • Collection of vanilla maps, factions, weapons, and more
  • Alternative interfaces for synchronous applications
  • Compatible with both Hell Let Loose and Hell Let Loose: Vietnam
  • Well-typed and tested

Installation

pip install hllrcon

Usage

import asyncio
from hllrcon import HLLRcon, HLLLayer


async def main():
    # Initialize client
    rcon = HLLRcon(
        host="127.0.0.1",
        port=12345,
        password="your_rcon_password",
    )

    # Send commands. The client will (re)connect for you.
    await rcon.broadcast("Hello, HLL!")
    await rcon.change_map(Layer.STALINGRAD_WARFARE_DAY)
    players = await rcon.get_players()

    # Close the connection
    rcon.disconnect()


    # Alternatively, use the context manager interface to avoid
    # having to manually disconnect.
    async with rcon.connection():
        assert rcon.is_connected() is True
        await rcon.broadcast("Hello, HLL!")


if __name__ == "__main__":
    # Run the program
    asyncio.run(main())

Above example connects to servers running the original Hell Let Loose. Use HLLVRcon to connect to a Hell Let Loose: Vietnam server instead.

import asyncio
from hllrcon import HLLVRcon, HLLVLayer


async def main():
    # Initialize client
    rcon = HLLVRcon(
        host="127.0.0.1",
        port=12345,
        password="your_rcon_password",
    )

    # Connect and change the map
    async with rcon.connection():
        await rcon.change_map(HLLVLayer.THANHHOABRIDGE_WARFARE_DAY)

if __name__ == "__main__":
    asyncio.run(main())

For integration of synchronous applications, the HLLSyncRcon and HLLVSyncRcon classes are provided.

from hllrcon.sync import SyncRcon

rcon = HLLSyncRcon(
    host="127.0.0.1",
    port=12345,
    password="your_rcon_password",
)

# Connect and send a broadcast message
with rcon.connection():
    rcon.broadcast("Hello, HLL!")

The library contains a swathe of details about in-game maps, factions, weapons, vehicles, and more. Below is just an example of what it might be used for.

from hllron import HLLWeapon

# Find a weapon by its ID
weapon_id = "COAXIAL M1919 [Stuart M5A1]"
weapon = HLLWeapon.by_id(weapon_id)

# Print out whichever vehicle seat the attacker must have been in, if any
if weapon.vehicle:
    for seat in weapon.vehicle.seats:
        if weapon in seat.weapons:
            print("This weapon belongs to the", seat.type.name, "seat")
            break
from hllrcon import HLLRcon, HLLTeam

# Get the AA Network capture zone (SMDM, 3rd sector, 2nd capture zone)
sector = Layer.STMARIEDUMONT_WARFARE_DAY.sectors[2]
capture_zone = sector.capture_zones[1]
assert capture_zone.strongpoint.name == "AA Network"

# Get the current online players
rcon = HLLRcon(...)
players = await rcon.get_players()

# Calculate each team's capture strength towards the sector
strength = {HLLTeam.ALLIES: 0, HLLTeam.AXIS: 0}
for player in players.players:
    if player.faction is None:
        continue

    if player.world_position == (0.0, 0.0, 0.0):
        # Player is dead. Note: Does not exclude players bleeding out
        continue

    # Grant 3 strength if inside the strongpoint
    if capture_zone.strongpoint.is_inside(player.world_position):
        strength[player.faction.team] += 3

    # Only grant 1 strength if inside the capture zone
    elif capture_zone.is_inside(player.world_position):
        strength[player.faction.team] += 1

# Print out the results
print("Allied cap weight:", strength[HLLTeam.ALLIES])
print("Axis cap weight:", strength[HLLTeam.AXIS])

Versioning

The Hell Let Loose franchise is constantly evolving, and game updates might alter its games' RCON interfaces in ways that are not backward-compatible. This affects any tools and libraries that depend on it, including this library and any software utilizing it.

Releases of hllrcon only guarantee compatibility with the latest version of Hell Let Loose and Hell Let Loose: Vietnam at the time of release. See the release notes of a given version for more information on what version this is.

This project uses its own versioning system similar to Pragmatic Versioning principles (i.e. GRADE.MAJOR.MINOR.PATCH). However, there are differences in the way each of the four components are defined and what they guarantee:

  • GRADE - Reserved for structural changes. Likely to increase only with the release of Hell Let Loose: Vietnam.
  • MAJOR - Incremented when backward-incompatible changes are released.
  • MINOR - Incremented when support for the previously supported game version is dropped.
  • PATCH - Incremented when backward-compatible changes are released.

When specifying hllrcon as a dependency, it is recommended to pin the MINOR version but not the PATCH version. MINOR versions are still backward-incompatible in that they require the game server to be updated. MINOR versions may be released before the game update it depends on.

License

This project is licensed under the MIT License. See LICENSE for details.

Metadata

Release files for hllrcon 2.0.0.7

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for hllrcon 2.0.0.7
File Size Uploaded Provenance Actions
hllrcon-2.0.0.7.tar.gz 233.9 kB With provenance Details for hllrcon-2.0.0.7.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for hllrcon 2.0.0.7
File Interpreter ABI Platform Actions
hllrcon-2.0.0.7-py3-none-any.whl Python 3 none any Details for hllrcon-2.0.0.7-py3-none-any.whl

Total release size: 356.6 kB

Release files / hllrcon-2.0.0.7.tar.gz

Download URL hllrcon-2.0.0.7.tar.gz
Size 233.9 kB
Tags Source
SHA-256 checksum
How to use checksums
9ff366396fb2bb3856ebfe77c52689cbc0aa3c6896b40f6cb3ea29272db5e139
BLAKE2b-256 checksum
How to use checksums
2f53815c40dc940c0d921c2fd1c3f1f7825c1ec60931edce12f23da99f30e490
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 23, 2026.

Transparency log

Release files / hllrcon-2.0.0.7-py3-none-any.whl

Download URL hllrcon-2.0.0.7-py3-none-any.whl
Size 122.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
befc2464379b38e4a19eda8f63d649228af0b43e99a4bb526898d822b56a10e2
BLAKE2b-256 checksum
How to use checksums
d9a2bcaf34a554114c2bd0c6e2b675554ed4cbbac5cb5b656d13422b237610d2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 23, 2026.

Transparency log

Security for hllrcon 2.0.0.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for hllrcon-2.0.0.7.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 23, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page