User Floor-Based Addressing
User Floor-Based Addressing#
This mod sets DHCP mode, DNS servers, and assigns network addresses based on floor number and user increment.
| Version | 0.1.12 |
| Author | CJFWeatherhead |
| Status | 🟢 Active Development |
| Game Version | 0.10.11+ |
| Last Updated | 2026-05-31 |
Download#
Installation Instructions
Using Mod Manager (Recommended)#
- Download the Mod Manager
- Find User Floor-Based Addressing in the Available mods list
- Click Download to install automatically
- Configure parameters in the GUI
Manual Installation#
- Download the zip file above
- Extract the
user-floor-addressing/folder to your mods directory:- Windows:
%APPDATA%\Godot\app_userdata\Tower Networking Inc\mods\ - Linux:
~/.local/share/godot/app_userdata/Tower Networking Inc/mods/
- Windows:
- Ensure luajit.elf is in the mods directory
Configuration#
Configure these settings using the Mod Manager or edit entry.lua directly.
| Parameter | Type | Default | Description |
|---|---|---|---|
| Network Address Format | string | @f%d/usr%d | Format string for network addresses. Two %d placeholders are replaced with floor number and user increment (e.g., “@f%d/usr%d” becomes “@f0/usr1”) |
| DHCP Mode | select: disabled, boot_dhcp, periodic_dhcp | boot_dhcp | DHCP mode for users. boot_dhcp = DHCP on boot only, periodic_dhcp = periodic DHCP requests, disabled = manual only |
| Floor DNS Server Format | string | @f%d/dns | Format string for floor-specific DNS servers. %d is replaced with floor number (e.g., “@f%d/dns” becomes “@f0/dns”) |
| Fallback DNS Server 1 | string | @srv/dns1 | First fallback DNS server if floor-specific DNS is unavailable |
| Fallback DNS Server 2 | string | @srv/dns2 | Second fallback DNS server |
About This Mod#
This mod sets DHCP mode, DNS servers, and assigns network addresses based on floor number and user increment.
Features#
- Sets DHCP mode (default: “boot_dhcp”) for all users
- Assigns addresses like “@f{floor}/usr{increment}” (configurable format)
- Configures DNS servers with a floor-specific primary and two configurable fallbacks
- Tracks user count per floor for incremental addressing
Limitations#
- Hardware (MAC) address control is not supported – the mod API does not expose any method to set or refresh hardware addresses.
- Phone and CCTV addressing is not supported – these are fixture outlets managed by MultiplayerSpawner nodes and are not accessible via the Lua mod API.
Full Documentation
User Floor-Based Addressing Mod#
This mod automatically configures network settings for users when they spawn in the game.
Features#
- DHCP Configuration: Sets DHCP mode per configuration (
boot_dhcpby default) - Floor-Based Addressing: Assigns predictable network addresses based on floor number and user count
- Format is configurable, default:
@f<floor>/usr<increment> - Example: User #5 on floor 3 gets address
@f3/usr5 - Example: User #1 on floor 10 gets address
@f10/usr1
- Format is configurable, default:
- Automatic DNS Setup: Configures a floor-specific primary DNS plus two fallback DNS servers
How It Works#
The mod hooks into the on_user_spawned callback, triggered whenever a new user is created:
- Retrieves the user’s logic controller and network control module
- Gets the floor number from the user’s location
- Maintains a counter of users per floor
- Generates a predictable network address based on floor and user count
- Sets DHCP mode (default:
boot_dhcp) - Configures DNS servers: floor-specific primary, then two configurable fallbacks
Limitations#
Hardware (MAC) Addresses: The mod API does not expose any method to set or refresh hardware addresses. Hardware addresses are assigned by the game engine and cannot be controlled by mods.
Phone / CCTV Devices: Phones and CCTVs are fixture outlets
(DeviceOutlet/PoweredDeviceOutlet) instantiated by MultiplayerSpawner
nodes in the scene tree. They are not accessible via the Lua mod API — there
is no on_fixture_spawned callback and no API method to enumerate them.
Installation#
- Copy the
user-floor-addressingfolder to yourmods/directory - The mod will be automatically loaded when the game starts
- Press F11 to reload the mod without restarting the game
Technical Details#
DHCP Modes#
The game supports three DHCP modes:
"disabled"- DHCP disabled, manual configuration required"boot_dhcp"- Request DHCP address on boot"periodic_dhcp"- Periodically request DHCP updates
DNS Configuration#
DNS servers are set using a Godot Array. By default:
- Floor-specific:
@f<floor>/dns - Fallback 1:
@srv/dns1 - Fallback 2:
@srv/dns2
All three are configurable via format strings.
Address Format#
Addresses use a configurable printf-style format with two %d placeholders
(floor number, user increment). Default: @f%d/usr%d.
Compatibility#
- Tested with game version: 0.10.11+
- Compatible with other mods that don’t modify user network settings
- Works alongside device modification mods and reward scaling mods (e.g.
floor-reward-scaling)
Additional Notes
DHCP modes available: “disabled”, “boot_dhcp”, “periodic_dhcp”. Uses on_user_spawned hook.
Technical Details
| Field | Value |
|---|---|
| Mod ID | user-floor-addressing |
| Creation Date | 2026-01-01 |
| Last Updated | 2026-05-31 |
| Game Version | 0.10.11+ |
| Dependencies | None |
| Website | https://github.com/CJFWeatherhead/TNI-Mods/tree/main/lua/user-floor-addressing |
Release URLs: