pub struct LoadStaticZone {
    pub zone_id: ZoneId,
    pub map_checksum: u32,
    pub player_position: Vector3,
    pub instance_type: InstanceType,
}
Expand description

Tells the client to load a zone.

Trigger

May be sent at any time. However, in a typical server instance architecture, this message will usually be sent as the first message directly after the client has validated itself with ClientValidation.

Handling

Load the zone specified in zone_id, whatever that may entail for your client implementation.

Response

Respond with LevelLoadComplete once you’re done loading.

Notes

Server instances are usually statically assigned to host a “parallel universe” of a certain zone (world), which means that this message will be sent directly after client validation. However, other instance architectures are theoretically possible:

  • Dynamic changing of the instance’s zone, in which case additional LoadStaticZone messages could be sent (when the zone is changed).

  • Shared/overlapping instances, where the instance connection changes as the player moves around in the world, or where instances take over from others (e.g. in the event of a reboot), with mobs and all other state being carried over. In this case the client would be instructed to connect to the new instance via TransferToWorld, but would not receive a LoadStaticZone afterwards. If done correctly, the player wouldn’t even notice the transfer at all.

However, these are quite advanced architectures, and for now it is unlikely that any server project will actually pull these off.

Fields

zone_id: ZoneId

ID of the zone to be loaded.

map_checksum: u32

Checksum on the map on the server side. The original LU client will refuse to load any map where the client side checksum doesn’t match the server checksum, to prevent inconsistencies and cheating.

player_position: Vector3

The position of the player in the new world, likely used to be able to load the right part of the world.

instance_type: InstanceType

The instance type of the zone being loaded.

Trait Implementations

Formats the value using the given formatter. Read more
Deserializes the type by reading from the reader.
Converts to this type from the input type.
Converts to this type from the input type.
This method tests for self and other values to be equal, and is used by ==. Read more
This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason. Read more
Serializes the type by writing to the writer.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.