Skip to content

Lobbies

YYBartT edited this page Mar 7, 2024 · 11 revisions

Lobbies and Matchmaking

The following functions and constants allow you to use Steam's Lobbies and Matchmaking functionality.

Current Lobby

These functions are provided for handling the current lobby:

Matchmaking

The following functions allow retrieving and handling lists of public lobbies:

Constants

These are the constants used by this API:



Back To Top

steam_lobby_activate_invite_overlay

This function displays an invitation overlay if currently in a lobby. The invitation overlay is much akin to the friends-list overlay, but only shows online friends, and shows an "invite" button on each row.

This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Steam Async Event.


Syntax:

steam_lobby_activate_invite_overlay()

Returns:

Boolean


Triggers:

Steam Async Event

(when an invitation is accepted)

Key Type Description
event_type String The string value "lobby_join_requested"
lobby_id Int64 The lobby unique identifier
success Boolean Whether or not the task was successful
result Real The code of the result

Example:

steam_lobby_activate_invite_overlay();

The above code will show the Steam invite overlay.




Back To Top

steam_lobby_create

This function starts creating a lobby. Returns whether or not the task was successfully created.

This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Steam Async Event.


Syntax:

steam_lobby_create(type, max_members)
Argument Type Description
type LobbyType A constant that indicates the status of the lobby
max_members Real Indicates the maximum allowed number of users in the lobby (including the lobby's creator)

Returns:

Boolean


Triggers:

Steam Async Event

Key Type Description
event_type String The string value "lobby_created"
lobby_id Int64 The name of the lobby
success Real Whether or not the request was successful
result Boolean The status code (descriptions can be found in Steam API documentation)

This event is triggered when someone enters or leaves a lobby.

Key Type Description
event_type String The string value "lobby_chat_update"
lobby_id Int64 The ID of the lobby
change_flags Real 1 for new connection on lobby, 2 for disconnect, 4 if the user disconnected without leaving the lobby first, 8 if the user has been kicked, 16 if the user has been kicked and banned.
user_id Int64 the Steam ID of the user that joined or left the lobby
change_id Int64 the ID that has "changed", the same as user_id

Example:

var _type = async_load[? "type"];
if (_type == "lobby_created")
{
    if (async_load[? "success"])
        show_debug_message("Lobby created");
    else
        show_debug_message("Failed to create lobby");
}

in the example we are simply outputting the success of the lobby creation task.




Back To Top

steam_lobby_get_chat_message_data

This function returns the data of a message sent using steam_lobby_send_chat_message_buffer. It returns whether or not the buffer was successfully filled with the message data.


Syntax:

steam_lobby_get_chat_message_data(message_index, buffer)
Argument Type Description
message_index Real The message unique identifier
buffer Buffer The buffer to write the data to

Returns:

Boolean


Example:

chat_message_buf = buffer_create(steam_lobby_max_chat_message_size, buffer_fixed, 1);
steam_lobby_get_chat_message_data(_msg_index, chat_message_buf);

The code above will get the current message data and place it into a buffer (resizing if required and allowed, i.e.: buffer_grow).




Back To Top

steam_lobby_get_chat_message_size

This function returns the size of a message.


Syntax:

steam_lobby_get_chat_message_size(message_index)
Argument Type Description
message_index Real The argument to be passed in

Returns:

Real


Example:

///@desc Async Steam Event
switch (async[? "event_type"])
{
    case "lobby_chat_message":
        size = steam_lobby_get_chat_message_size(async_load[?"message_index"]);
        break;
}

The code above will get the current message size in bytes.




Back To Top

steam_lobby_get_chat_message_text

This function returns the text of a message.


Syntax:

steam_lobby_get_chat_message_text(index)
Argument Type Description
index Real Message index

Returns:

String


Example:

///@desc Async Steam Event
switch (async[? "event_type"])
{
    case "lobby_chat_message":
        text = steam_lobby_get_chat_message_text(async_load[?"message_index"]);
        break;
}

The code above will get the current message text.




Back To Top

steam_lobby_get_data

This function returns a lobby field value, as set by steam_lobby_set_data.


Syntax:

steam_lobby_get_data(key)
Argument Type Description
key String String representation of the data

Returns:

String


Example:

var _title = steam_lobby_get_data("title");

The code above will return the data of the title field of the current value.




Back To Top

steam_lobby_get_lobby_id

This function returns the Steam ID of the current lobby.


Syntax:

steam_lobby_get_lobby_id()

Returns:

Int64


Example:

var _lobby_id = steam_lobby_get_lobby_id();

The code above will get the current lobby ID and store it in a variable.




Back To Top

steam_lobby_get_member_count

This function returns the number of users in the current lobby (including you). If the lobby is not valid, it returns 0.


Syntax:

steam_lobby_get_member_count()

Returns:

Real


Example:

for(var i = 0 ; i < steam_lobby_get_member_count() ; i++)
{
    var _user_id = steam_lobby_get_member_id(i);
    //Do something with the user ID
}

The code sample above will get the total number of member in the current lobby and iterate over all of them getting their unique ID's, using the steam_lobby_get_member_id function.




Back To Top

steam_lobby_get_member_id

This function returns the user ID of the member at the given index in the current lobby.


Syntax:

steam_lobby_get_member_id(index)
Argument Type Description
index Real Position of the member of the lobby to return

Returns:

Int64


Example:

for(var i = 0 ; i < steam_lobby_get_member_count() ; i++)
{
    var _user_id = steam_lobby_get_member_id(i);
    //Do something with the user id
}

The code sample above will iterate over all of the members inside a lobby and get their unique ID's.




Back To Top

steam_lobby_get_owner_id

This function returns the lobby owner's Steam ID. If the lobby is not valid, returns ID 0.


Syntax:

steam_lobby_get_owner_id()

Returns:

Int64


Example:

var _lobby_owner = steam_lobby_get_owner_id();

The code above will return the unique ID of the owner of the current lobby.




Back To Top

steam_lobby_is_owner

This function returns whether the local player is the lobby's owner.

Note

If the lobby is not valid, this function returns false.


Syntax:

steam_lobby_is_owner()

Returns:

Boolean


Example:

for (var i = 0; i < steam_lobby_get_member_count(); i++)
{
    if (!steam_lobby_is_owner())
    {
        var _user_id = steam_lobby_get_member_id(i);
        steam_lobby_set_owner_id(_user_id);
        break;
    }
}

The code example will loop through all the members in a lobby and transfers ownership to the first member that is not the owner.




Back To Top

steam_lobby_join_id

This function starts joining the lobby with the given ID. Returns whether or not the API was correctly initialized.

This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Steam Async Event.


Syntax:

steam_lobby_join_id(lobby_id)
Argument Type Description
lobby_id Int64 Identifier of the lobby

Returns:

N/A


Triggers:

Steam Async Event

Key Type Description
event_type String The string value "lobby_joined"
lobby_id Int64 The lobby unique identifier
success Boolean Whether or not the task was successful
result Real The code of the result

This event is triggered when someone enters or leaves a lobby.

Key Type Description
event_type String The string value "lobby_chat_update"
lobby_id Int64 The ID of the lobby
change_flags Real 1 for new connection on lobby, 2 for disconnect, 4 if the user disconnected without leaving the lobby first, 8 if the user has been kicked, 16 if the user has been kicked and banned.
user_id Int64 the Steam ID of the user that joined or left the lobby
change_id Int64 the ID that has "changed", the same as user_id

Example:

steam_lobby_join_id(lobbyID);

The code will attempt the join a lobby with a given ID, the task callback can be listened to inside the the Steam Async Event with the folllowing sample code:

var _type = async_load[? "type"];
if (_type == "lobby_joined")
{
    var _lobby_id = async_load[? "lobby_id"];
    var _success = async_load[? "success"];

    // Do something with the data
}

In the example we are simply caching the data into variables.




Back To Top

steam_lobby_leave

This function leaves the current lobby (if any). It does not raise any errors if currently not in a lobby.

Note

If you are the lobby owner and leave the lobby, Steam transfers the lobby ownership to any other available user, so you may need to manually handle ownership transfer using steam_lobby_set_owner_id before leaving.

This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Steam Async Event.


Syntax:

steam_lobby_leave()

Returns:

N/A


Triggers:

Steam Async Event

This event is triggered when someone enters or leaves a lobby.

Key Type Description
event_type String The string value "lobby_chat_update"
lobby_id Int64 The ID of the lobby
change_flags Real 1 for new connection on lobby, 2 for disconnect, 4 if the user disconnected without leaving the lobby first, 8 if the user has been kicked, 16 if the user has been kicked and banned.
user_id Int64 the Steam ID of the user that joined or left the lobby
change_id Int64 the ID that has "changed", the same as user_id

Example:

steam_lobby_leave();

The code sample above will make the user leave the current lobby.




Back To Top

steam_lobby_send_chat_message

This function broadcasts a chat text message to all the users in the lobby.

This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Steam Async Event.


Syntax:

steam_lobby_send_chat_message(text)
Argument Type Description
text String The string to be sent (up to 4000 characters)

Returns:

Boolean


Triggers:

Steam Async Event

Key Type Description
event_type String The string value "lobby_chat_message"
user_id String The sender unique identifier
message_index Real The message unique identifier

Example:

steam_lobby_send_chat_message("Hello World");

The code will broadcast a text message to all the members in the current lobby, the message can be read using the Steam Async Event callback:

var _type = async_load[? "type"];
if (_type == "lobby_chat_message")
{
    var _user_id = async_load[? "user_id"];
    var _msg_id = async_load[? "message_index"];

    var _user_name = steam_get_user_persona_name_sync(_user_id);
    var _message = steam_lobby_get_chat_message_text(_msg_id);

    // Do something with the data
}

In the example we are simply caching the data into variables. Notice that use use the functions steam_get_user_persona_name_sync and steam_lobby_get_chat_message_text to get both the user name and the text inside the message, respectively.




Back To Top

steam_lobby_send_chat_message_buffer

This function broadcasts a chat (text or binary data) message to all the users in the lobby.

This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Steam Async Event.


Syntax:

steam_lobby_send_chat_message_buffer(buffer, size)
Argument Type Description
buffer Buffer The buffer to be sent (up to 4 Kilobytes in size)
size Real The number of bytes to be sent (there is no offset).

Returns:

Boolean


Triggers:

Steam Async Event

Key Type Description
event_type String The string value "lobby_chat_message"
user_id String The sender unique identifier
entry_type Real The type of message received.
message_index Real The message unique identifier
message_size Real The size of the message being broadcasted

Example:

var _buff = buffer_create(256, buffer_fixed, 1);
buffer_write(_buff, buffer_string, "This is a buffer!");
steam_lobby_send_chat_message_buffer(_buff);

The code will broadcast a message (text or binary data) to all the members in the current lobby, the message can be read using the Steam Async Event callback:

var _type = async_load[? "type"];
if (_type == "lobby_chat_message")
{
    var _user_id = async_load[? "user_id"];
    var _msg_id = async_load[? "message_index"];

    var _user_name = steam_get_user_persona_name_sync(_user_id);
    var _data = steam_lobby_get_chat_message_data(global.chat_buffer, _msg_id);

    // Do something with the data
}

In the example we are simply caching the data into variables notice that use use the functions steam_get_user_persona_name_sync and steam_lobby_get_chat_message_data to get both the user name and the data inside the message, respectively.




Back To Top

steam_lobby_set_data

This function changes a lobby's field. You must be the lobby owner to do this. The function returns whether or not the data was set. Fields can then be used to filter lobbies via matchmaking functions.

Note

If your value is numeric, convert it to string prior to passing it to the function.


Syntax:

steam_lobby_set_data(key, value)
Argument Type Description
key String The key to set the data for
value String The value to set

Returns:

Boolean


Example:

steam_lobby_set_data("LobbyName", "GreatLobby");

The code sample will set the "LobbyName" lobby field to the provided value "GreatLobby".




Back To Top

steam_lobby_set_joinable

This function sets whether or not a lobby is joinable by other players. This always defaults to enabled for a new lobby. Returns whether or not the property was set.

Note

If joining is disabled, then no players can join, even if they are a friend or have been invited.

Note

Lobbies with joining disabled will not be returned from a lobby search.


Syntax:

steam_lobby_set_joinable(joinable)
Argument Type Description
joinable Boolean Allow ( true ) or prevent ( false ) users from joining this lobby

Returns:

Boolean


Example:

steam_lobby_set_joinable(false);

The code above will prevent user from joining the current lobby.




Back To Top

steam_lobby_set_owner_id

If you are a lobby owner, this function transfers the lobby ownership to the specified player, which must be in this same lobby. Returns whether or not the property was set.

Note

You need to be the lobby owner in order to use the function.


Syntax:

steam_lobby_set_owner_id(user_id)
Argument Type Description
user_id Boolean The user to set as owner of the lobby

Returns:

Boolean


Example:

for(var i = 0 ; i < steam_lobby_get_member_count() ; i++)
{
    if(!steam_lobby_is_owner())
    {
        var _user_id = steam_lobby_get_member_id(i);
        steam_lobby_set_owner_id(_user_id);
        break;
    }
}

The code example will loop through all the members in a lobby and transfers ownership to the first member that is not the owner.




Back To Top

steam_lobby_set_type

This function changes the lobby's type. Useful, if you don't allow mid-session joining, you could have the game make lobbies private on session start (or use steam_lobby_set_joinable).

Note

You need to be the lobby owner in order to use the function.


Syntax:

steam_lobby_set_type(type)
Argument Type Description
type LobbyType The lobby visibility

Returns:

N/A


Example:

steam_lobby_set_type(steam_lobby_type_private);

The code above will change the lobby joining policy.




Back To Top

steam_lobby_list_add_distance_filter

This function restricts results by region and sorts them based on geographical proximity.


Syntax:

steam_lobby_list_add_distance_filter(mode)
Argument Type Description
mode LobbyFilterDistanceMode The distance filter to be applied

Returns:

Boolean


Example:

steam_lobby_list_add_distance_filter(steam_lobby_list_distance_filter_far);
steam_lobby_list_add_near_filter("myNearFilter", 77);
steam_lobby_list_add_numerical_filter("level", 10, steam_lobby_list_filter_gt);
steam_lobby_list_add_string_filter("Stage","BattleZone", steam_lobby_list_filter_eq);
steam_lobby_list_request();

The code above will apply some filters to be lobby list request before requesting the results.




Back To Top

steam_lobby_list_add_near_filter

This function sorts the results based on how close their field's key's value is to the provided one.

Note

If multiple near-filters are specified, the earlier set ones take precedence.


Syntax:

steam_lobby_list_add_near_filter(key, value)
Argument Type Description
key String The filter key name to match.
value Real The value that lobbies will be sorted on.

Returns:

Boolean


Example:

steam_lobby_list_add_distance_filter(steam_lobby_list_distance_filter_far);
steam_lobby_list_add_near_filter("myNearFilter", 77);
steam_lobby_list_add_numerical_filter("level", 10, steam_lobby_list_filter_gt);
steam_lobby_list_add_string_filter("Stage","BattleZone", steam_lobby_list_filter_eq);
steam_lobby_list_request();

The code above will apply some filters to be lobby list request before requesting the results.




Back To Top

steam_lobby_list_add_numerical_filter

This function sets up a numeric filter for the next lobby list request. That is, lobbies not matching the condition will be excluded from results.

Note

Lobbies without the given field (key) will be excluded.


Syntax:

steam_lobby_list_add_numerical_filter(key, value, comparison_type)
Argument Type Description
key String The filter key name to match
value Real The number to compare.
comparison_type LobbyFilterComparisonType The type of comparison to make.

Returns:

Boolean


Example:

steam_lobby_list_add_distance_filter(steam_lobby_list_distance_filter_far);
steam_lobby_list_add_near_filter("myNearFilter", 77);
steam_lobby_list_add_numerical_filter("level", 10, steam_lobby_list_filter_gt);
steam_lobby_list_add_string_filter("Stage","BattleZone", steam_lobby_list_filter_eq);
steam_lobby_list_request();

The code above will apply some filters to a lobby list request before requesting the results.




Back To Top

steam_lobby_list_add_string_filter

This function sets up a string filter for the next lobby list request. That is, lobbies not matching the condition will be excluded from results.

Note

Lobbies without the given field (key) will be assumed to have it as "".


Syntax:

steam_lobby_list_add_string_filter(key, value, comparison_type)
Argument Type Description
key String The filter key name to match
value String The string to compare
comparison_type LobbyFilterComparisonType The type of comparison to make (strings only accept equal or not equal comparison)

Returns:

Boolean


Example:

steam_lobby_list_add_distance_filter(steam_lobby_list_distance_filter_far);
steam_lobby_list_add_near_filter("myNearFilter", 77);
steam_lobby_list_add_numerical_filter("level", 10, steam_lobby_list_filter_gt);
steam_lobby_list_add_string_filter("Stage","BattleZone", steam_lobby_list_filter_eq);
steam_lobby_list_request();

The code above will apply some filters to be lobby list request before requesting the results.




Back To Top

steam_lobby_list_get_count

This function returns the count of lobbies, after a successful call to steam_lobby_list_request.


Syntax:

steam_lobby_list_get_count()

Returns:

Real


Example:

for(var a = 0 ; a < steam_lobby_list_get_count() ; a++)
{
    ins = instance_create_depth(600, 200+90*a, 0, Obj_Steam_Networking_List_Slot);
    ins.index = a;
    ins.lobby_id = steam_lobby_list_get_lobby_id(a);
    ins.creator = steam_lobby_list_get_data(a, "Creator");
}

After a successful steam_lobby_list_request this function will return the number of results in the lobby query.




Back To Top

steam_lobby_list_get_data

This function gets the metadata associated with the specified key from the specified lobby.

Note

The argument lobby_index is not a lobby ID but instead the position of the lobby (from 0 to steam_lobby_list_get_count) on the query array after a steam_lobby_list_request async event is triggered.


Syntax:

steam_lobby_list_get_data(lobby_index, key)
Argument Type Description
lobby_index Real The lobby list index from the queried result.
key String The key to get the value of.

Returns:

String


Example:

for(var a = 0 ; a < steam_lobby_list_get_count() ; a++)
{
    ins = instance_create_depth(600,200+90*a,0,Obj_Steam_Networking_List_Slot);
    ins.index = a;
    ins.lobby_id = steam_lobby_list_get_lobby_id(a);
    ins.creator = steam_lobby_list_get_data(a, "Creator");
}

The above code shows a code example.




Back To Top

steam_lobby_list_get_lobby_id

This function gets the lobby ID associated with the index.

Note

The argument lobby_index is not a lobby ID but instead the position of the lobby (from 0 to steam_lobby_list_get_count) on the query array after a steam_lobby_list_request async event is triggered.


Syntax:

steam_lobby_list_get_lobby_id(lobby_index)
Argument Type Description
lobby_index Real The lobby index in the current lobby list

Returns:

Int64


Example:

for(var a = 0; a < steam_lobby_list_get_count(); a++)
{
    ins = instance_create_depth(600, 200+90*a, 0, Obj_Steam_Networking_List_Slot);
    ins.index = a;
    ins.lobby_id = steam_lobby_list_get_lobby_id(a);
    ins.creator = steam_lobby_list_get_data(a, "Creator");
}

The above code shows a code example.




Back To Top

steam_lobby_list_get_lobby_member_count

This function gets the number of users in a lobby.

Note

The argument lobby_index is not a lobby ID but instead the position of the lobby (from 0 to steam_lobby_list_get_count) on the query array after a steam_lobby_list_request async event is triggered.


Syntax:

steam_lobby_list_get_lobby_member_count(lobby_index)
Argument Type Description
lobby_index Real The lobby ID of the lobby to get the number of members of.

Returns:

Real


Example:

steam_lobby_list_get_lobby_member_count(steam_lobby_get_lobby_id());

The above code shows a code example.




Back To Top

steam_lobby_list_get_lobby_member_id

This function gets the Steam ID of the lobby member at the given index.

Note

The argument lobby_index is not a lobby ID but instead the index representation of the lobby (ranging from 0 to steam_lobby_list_get_count) on the query array after a steam_lobby_list_request async event is triggered. By the same logic the member_index is also not the user ID but the indexed representation of the user within the lobby (this value ranges from 0 to steam_lobby_list_get_lobby_member_count).


Syntax:

steam_lobby_list_get_lobby_member_id(lobby_index, member_index)
Argument Type Description
lobby_index Real This MUST be an index ranging from 0 to steam_lobby_list_get_count
member_index Real This MUST be an index ranging from 0 to steam_lobby_list_get_lobby_member_count of the lobby index

Returns:

Int64


Example:

var _count = steam_lobby_list_get_lobby_member_count(steam_lobby_get_lobby_id());
for(var i = 0 ; i < _count ; i++)
{
     var _member = steam_lobby_list_get_lobby_member_id(i);
     //do something with the member id
}

The above code will show a code example.




Back To Top

steam_lobby_list_get_lobby_owner_id

This function returns the current lobby owner.

Note

The argument lobby_index is not a lobby ID but instead the position of the lobby (from 0 to steam_lobby_list_get_count) on the query array after a steam_lobby_list_request async event is triggered.


Syntax:

steam_lobby_list_get_lobby_owner_id(index)
Argument Type Description
index Real The lobby index from the lobby list request result

Returns:

Int64


Example:

steam_lobby_list_get_lobby_owner_id(steam_lobby_get_lobby_id());

The above code will show a code example.




Back To Top

steam_lobby_list_is_loading

This function returns whether a lobby list request is currently underway.


Syntax:

steam_lobby_list_is_loading()

Returns:

Boolean


Example:

steam_lobby_list_request();

// Later in code

if (steam_lobby_list_is_loading)
    show_message("Loading");

The above will code will check to see if the lobby list request is still loading or has finished.




Back To Top

steam_lobby_list_join

Starts joining a lobby with the given ID.

This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Steam Async Event.


Syntax:

steam_lobby_list_join(index)
Argument Type Description
index Real Position of the lobby in the list

Returns:

N/A


Triggers:

Steam Async Event

Key Type Description
event_type String The string value "lobby_joined"
lobby_id Int64 The lobby unique identifier
success Boolean Whether or not the task was successful
result Real The code of the result

Example:

steam_lobby_list_join(0);

The code sample above can be used to join a lobby with the given index after a steam_lobby_list_request has been performed.




Back To Top

steam_lobby_list_request

This function starts loading the list of lobbies matching the current filters.

Note

Filters are reset afterwards and have to be set again for subsequent request(s).

Note

Existing results are kept up until the event is dispatched.

This function operates asynchronously, which means that it does not immediately return the requested result. Instead, upon completion of the task, it will trigger the Steam Async Event.


Syntax:

steam_lobby_list_request()

Returns:

N/A


Triggers:

Steam Async Event

Key Type Description
event_type String The string value "lobby_list"
lobby_count Int64 The number of lobbies in retrieved (same as steam_lobby_list_get_count)
success Boolean Whether or not the task was successful
result Real The code of the result

Example:

steam_lobby_list_add_distance_filter(steam_lobby_list_distance_filter_far);
steam_lobby_list_add_near_filter("myNearFilter", 77);
steam_lobby_list_add_numerical_filter("level", 10, steam_lobby_list_filter_gt);
steam_lobby_list_add_string_filter("Stage","BattleZone", steam_lobby_list_filter_eq);
steam_lobby_list_request();

In this extended example we will request the lobby list that matches the requested filter criteria and parse its results in the Steam Async Event. To start with we need to request the lobbies with the code above. And afterwards proceed to catch the results after/during the corresponding asynchronous event:

var _type = ds_map_find_value(async_load, "event_type");
if (_type == "lobby_list")
{
    var _lb_count = steam_lobby_list_get_count();
    for (var i = 0; i < _lb_count; i++)
    {
        var _lb_ID = steam_lobby_list_get_lobby_id(i);
        var _lb_owner = steam_lobby_list_get_lobby_owner_id(i);
        var _lb_members_count = steam_lobby_list_get_lobby_member_count(i);
        for (var j = 0; j < _lb_members_count; j++)
        {
            var _lb_member_ID = steam_lobby_list_get_lobby_member_id(i, j);
            // Do what even you need with the queried information
        }
    }
}

This code will loop through all the loobies and respective members on the query result.




Back To Top

LobbyFilterComparisonType

These constants specify the comparison type when applying a filter to a lobby list request.

These constants are referenced by the following functions:


Member Description
steam_lobby_list_filter_eq Equal (==).
steam_lobby_list_filter_ne Not-equal (!=)
steam_lobby_list_filter_lt Less-than (<), only applies to steam_lobby_list_add_numerical_filter
steam_lobby_list_filter_gt Greater-than (>), only applies to steam_lobby_list_add_numerical_filter
steam_lobby_list_filter_le Less-than-or-equal (<=), only applies to steam_lobby_list_add_numerical_filter
steam_lobby_list_filter_ge Greater-than-or-equal (>=), only applies to steam_lobby_list_add_numerical_filter


Back To Top

LobbyFilterDistanceMode

These constants specify the distance mode to be used when applying a filter to a lobby list request.

These constants are referenced by the following functions:


Member Description
steam_lobby_list_distance_filter_close Only allows lobbies in same immediate region
steam_lobby_list_distance_filter_default Allows lobbies in same or nearby regions (same continent)
steam_lobby_list_distance_filter_far Allows lobbies from up to half-way around the globe (nearby continents)
steam_lobby_list_distance_filter_worldwide Allows any lobbies. May result in very high latencies, so use with care


Back To Top

LobbyType

These constants specify the type of lobby should be used creating a new lobby.

These constants are referenced by the following functions:


Member Description
steam_lobby_type_private The lobby can only be joined by invitation
steam_lobby_type_friends_only The lobby can be joined by invitation or via friends-list (by opening the user's menu and picking "Join game")
steam_lobby_type_public The lobby can be joined by invitation, via friends-list and shows up in the public list (see matchmaking functions)