Skip to content

Commit

Permalink
relay: Allow setting custom primary relay address in .ini
Browse files Browse the repository at this point in the history
  • Loading branch information
IonAgorria committed Apr 21, 2024
1 parent ec2f36a commit 661c8c4
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Source/Network/NetRelay.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,11 @@

const char* getPrimaryNetRelayAddress() {
const char* cmdline_relay = check_command_line("netrelay");
return cmdline_relay ? cmdline_relay : NET_RELAY_DEFAULT_ADDRESS;
if (cmdline_relay) {
return cmdline_relay;
}
const char* ini_relay = IniManager("Perimeter.ini", false).get("Network","NetRelay");
return ini_relay ? ini_relay : NET_RELAY_DEFAULT_ADDRESS;
}

bool receiveNetRelayMessage(
Expand Down

0 comments on commit 661c8c4

Please sign in to comment.