GetServerPort
Jump to navigation
Jump to search
This function retrieves the server's port.
Syntax
int getServerPort ( )
Returns
An integer corresponding to the server's port.
Example
This example creates a console command that outputs the server's port to the chatbox.
function outputServerPort ( ) outputChatBox ( getServerPort( ) ) end -- Add console command 'getServerPort' addCommandHandler ( "getServerPort", outputServerPort )
See Also
- getMaxPlayers
- getServerConfigSetting
- getServerHttpPort
- getServerName
- getServerPassword
- getServerPort
- isGlitchEnabled
- setGlitchEnabled
- setMaxPlayers
- setServerConfigSetting
- setServerPassword
- shutdown