Dev's NoxDev's Nox
Relay Protocol

Join

Notification of a new player's arrival in an instance, sent to the existing participants.

The Join message is an automatic notification sent to the players of an instance when a new player successfully joins it.

It provides all the information needed to display and interact with the new player.

Priority

High - This message has a high priority to maintain the consistency of instance state.

The Join message is automatic and sent by the server. Clients cannot send it directly.


Server → Client Notification

Payload Format

[instance_id: byte]
[player_flags: uint]
[player_id: ushort]
[user_id: uint]
[server_address: string]
[display_name: string]
[created_at: DateTime]
[engine: string]
[platform: string]

Detailed Structure

TypeNameDescription
byteInstanceIDID of the instance concerned
uintPlayerFlagsFlags and permissions of the new player
ushortPlayerIDUnique player ID in the instance
uintUserIDAuthenticated user ID
stringServerAddressPlayer's server address
stringDisplayNamePlayer display name
DateTimeCreatedAtPlayer creation date and time
stringEngineEngine used (unity, unreal, etc.)
stringPlatformPlatform (windows, android, etc.)

Player Flags

ValueNameDescription
0x001IsBotThe player is a bot
0x002InstanceMasterReference player of the instance
0x004InstanceModeratorInstance moderator
0x008InstanceOwnerInstance owner
0x010GuildModeratorGuild moderator
0x020MasterModeratorMaster moderator
0x040WorldOwnerWorld owner
0x080WorldModeratorWorld moderator
0x100AuthUnverifiedAuthentication unverified
0x200HideInListHidden from lists
0x400HasCustomDisplayCustom display name

Notification Example - Regular Player

[0x05]                          // InstanceID = 5
[0x00, 0x00, 0x00, 0x00]        // PlayerFlags = None
[0x00, 0x04]                    // PlayerID = 4
[0x00, 0x00, 0x04, 0x2A]        // UserID = 1066
[0x0A, "nox.server"]            // ServerAddress = "nox.server"
[0x0C, "PlayerName123"]         // DisplayName = "PlayerName123"
[0x00, 0x00, 0x01, 0x8A, 0x32, 0x1F, 0x80, 0x00] // CreatedAt (timestamp)
[0x05, "unity"]                 // Engine = "unity"
[0x07, "windows"]               // Platform = "windows"

Notification Example - Bot

[0x02]                          // InstanceID = 2
[0x00, 0x00, 0x02, 0x01]        // PlayerFlags = IsBot | HideInList
[0x00, 0x08]                    // PlayerID = 8
[0x00, 0x00, 0x00, 0x00]        // UserID = 0 (bot)
[0x0A, "bot.server"]            // ServerAddress = "bot.server"
[0x07, "BotName"]               // DisplayName = "BotName"
[0x00, 0x00, 0x01, 0x8A, 0x32, 0x1F, 0x80, 0x00] // CreatedAt (timestamp)
[0x04, "node"]                  // Engine = "node"
[0x05, "linux"]                 // Platform = "linux"

Notification Example - Moderator

[0x01]                          // InstanceID = 1
[0x00, 0x00, 0x00, 0x04]        // PlayerFlags = InstanceModerator
[0x00, 0x01]                    // PlayerID = 1
[0x00, 0x00, 0x05, 0x39]        // UserID = 1337
[0x0A, "nox.server"]            // ServerAddress = "nox.server"
[0x0B, "ModeratorX"]            // DisplayName = "ModeratorX"
[0x00, 0x00, 0x01, 0x8A, 0x32, 0x1F, 0x80, 0x00] // CreatedAt (timestamp)
[0x06, "unreal"]                // Engine = "unreal"
[0x07, "windows"]               // Platform = "windows"

Automatic Synchronization

Avatar Data

Immediately after the Join message, the server automatically sends an AvatarChanged message if the new player has a configured avatar.

Transform Data

The server also sends all the Transform messages needed to synchronize the new player's position and state.

Message Order

  1. Join - Basic player information
  2. AvatarChanged - Avatar configuration (if present)
  3. Transform - Position and transformations (if configured)

Processing

Client Side

  1. Reception: Automatic message from the server
  2. Validation: Check of the instance ID
  3. Player addition: Creation of the local player object
  4. User interface: Display of the arrival notification
  5. Preparation: Waiting for the avatar and transform data

Server Side

  1. Trigger: On a successful Enter
  2. Distribution: Sending to all existing players
  3. Synchronization: Sending of the complementary data
  4. Logging: Recording of the event

Special Behaviors

Selective Distribution

The Join message is only sent to players with the PlayerStatus.Ready status in the same instance.

Sender Exclusion

The player joining the instance does not receive their own Join message. They instead receive a response to their Enter message.

Bidirectional Synchronization

When a new player joins:

  1. The existing players receive their Join message
  2. The new player receives the Join messages of all the existing players

Privilege Handling

Permission Display

The PlayerFlags allow clients to visually display privileges:

  • Moderator/owner icons
  • Special colors in the interface
  • Adapted context menus

Access Control

The flags influence the possible interactions:

  • Available moderation commands
  • Access to privileged features
  • Compliance with the permission hierarchy

Integration with Other Messages

Relation to Enter

The Join message is the notification resulting from a successfully processed Enter message.

Relation to Leave

When a player leaves via Leave, they are removed from the lists but their data remains until full cleanup.

Relation to Avatar/Transform

The Join messages are always followed by the necessary synchronization data.


Error Handling

Invalid Instance

If the instance ID does not match any local instance, the message is silently ignored.

Player Already Present

If the PlayerID already exists, the data is updated rather than duplicated.

Corrupted Data

In case of malformed data, the client must ignore the message and maintain its current state.


Usage Examples

User Interface

"PlayerName123 joined the instance"
"BotName (Bot) joined the instance"
"ModeratorX (Moderator) joined the instance"
"[Hidden Player] joined the instance" // For HideInList

Resource Initialization

Upon receiving a Join, the client must:

  1. Create the local player object
  2. Prepare the avatar rendering system
  3. Initialize the position data
  4. Update the instance counters
  5. Configure the interactions according to privileges
  6. Notify the user interface

Platform Detection

The Engine and Platform fields allow:

  • Platform-specific optimizations
  • Adaptation of the user interface
  • Feature compatibility
  • Usage statistics

On this page