Skip to main content
Class: SummerClientParty · Inherits: RefCounted · Access: Summer.client.party The player’s Summer party as this Game sees it. A Summer party belongs to the player’s account and follows them across Games. This view shows its members, its leader, which members have this Game open, data this Game shares with the party, and whether the party is searching a queue in this Game. The trusted Summer app owns creating parties, invitations, kicking, leadership transfer and chat; show_invite_dialog() and show_party_dialog() ask the app to present those screens. The Game never sees the party ID, invitations, chat, another Game’s data, or which other Game a member is playing. The view is a snapshot read through the Player Host whenever the party changes, when the event stream starts or resyncs, and on refresh(). Every signal is emitted after the snapshot is updated, once per real change. Getters return empty values outside a party and when is_available() is false: in local play, for a guest, or when the Summer app does not offer parties. To bring the party into a match, the leader joins SummerJoinTarget.party_queue(); every other member follows by joining the same target when search_started fires.
Games typically disable Play for members, show each member’s SummerPartyMember.in_game, and use set_data() so members see the leader’s selection. Host capabilities named here: player.party@1

Methods

get_all_data

Returns a copy of this Game’s party data as String keys and values. Empty outside a party. Returns: Dictionary

get_data

Returns this Game’s party data for key, or default when the key is not set. Returns: String

get_leader

Returns the party leader, or null outside a party. Returns: SummerPartyMember

get_local_member

Returns this player’s own member entry, or null outside a party. Returns: SummerPartyMember

get_member_limit

Returns the party’s maximum size, or 0 when it is unknown. Returns: int

get_members

Returns the current members in join order. Each entry is an immutable SummerPartyMember for the current snapshot; key your UI by SummerPartyMember.user_id. Returns: SummerPartyMember[]

get_search_queue

Returns the queue the party is searching in this Game, or an empty StringName when no party search is in progress. Returns: StringName

is_available

Returns true when the Summer app offers parties to this signed-in player. Always false in local play, for guests, for accounts the platform does not allow parties (age_restricted), and in Summer apps without the player.party@1 capability. Returns: bool

is_in_party

Returns true when the player currently belongs to a Summer party. Returns: bool

is_leader

Returns true when this player leads their party. Returns: bool

is_searching

Returns true while a party search in this Game is in progress. See get_search_queue(). Returns: bool

refresh

Reads the party snapshot again through the Player Host. Normally unnecessary: the Engine already re-reads it on every change. One read is in flight at a time; a second call while pending returns the same operation. Fails with capability_unavailable when is_available() is false, age_restricted when the platform refuses parties to this account, unavailable (retryable) when the Player Host cannot be reached, or protocol_error for a malformed snapshot, which changes nothing. Returns: SummerOperation Returns at once. Wait for the result with var result: SummerResult = await op.get_result_or_completed_signal(); see SummerOperation.

set_data

Sets this Game’s party data for key; an empty value deletes the key. Only the leader can set party data. Keys are 1 to 32 characters of a-z, 0-9, _, . and -; values are at most 256 UTF-8 bytes of text without control characters and pass the Summer chat text filter; a party holds at most 16 keys per Game. The Engine refuses before any network request with not_party_leader for a member, party_not_found outside a party, or invalid_argument for a key, value or key count outside these limits. The platform remains the authority and may still refuse with the same codes, or with text_not_allowed when the text filter rejects the value. Writes are applied in call order and fenced by the party version; if the party changed underneath a write, the Engine re-reads it and sends the write once more before failing with retryable party_version_conflict. On success, data_changed has already fired. Returns: SummerOperation Returns at once. Wait for the result with var result: SummerResult = await op.get_result_or_completed_signal(); see SummerOperation.

set_member_data

Sets this player’s own member data for this Game, such as ready or character; an empty value deletes the key. Any member can set their own data, up to 8 keys per Game. Key and value limits, ordering, version fencing and failures match set_data(), except that it is never refused for leadership. Member data is removed when the member leaves the party. Returns: SummerOperation Returns at once. Wait for the result with var result: SummerResult = await op.get_result_or_completed_signal(); see SummerOperation.

show_invite_dialog

Asks the Summer app to present its friend invite sheet over the game. The app creates a party first when the player has none. The operation completes when the app’s presenter answers. The Summer app answers as soon as the sheet is on screen, not when the player closes it, so the game keeps running and receives party changes while the sheet is open. It fails with ui_unavailable when the app cannot present the sheet right now and nothing is shown, and with capability_unavailable when is_available() is false. Invitations sent from the sheet reach the game only as later party changes. Returns: SummerOperation Returns at once. Wait for the result with var result: SummerResult = await op.get_result_or_completed_signal(); see SummerOperation.

show_party_dialog

Asks the Summer app to present party management (leave, kick, leadership transfer and party chat) over the game. Completes when the app’s presenter answers, as soon as the sheet is on screen; failures match show_invite_dialog(). One request is in flight at a time: while the app has not answered, asking for the same sheet returns the pending operation and asking for the other fails with retryable operation_in_progress. Returns: SummerOperation Returns at once. Wait for the result with var result: SummerResult = await op.get_result_or_completed_signal(); see SummerOperation.

Signals

changed

The party snapshot changed in any way this Game can see. Emitted once per change, after every more specific signal for that change.

data_changed

This Game’s party data for key was set, changed or deleted. Joining a party reports each key it already holds; leaving a party reports each key it held.

leader_changed

Leadership moved to member inside the same party. Joining or leaving a party reports the leader through member_joined and member_left instead.

member_data_changed

A member who stayed in the party set, changed or deleted their data for key. A joining member’s data arrives with member_joined.

member_in_game_changed

A member who stayed in the party opened or closed this Game; read SummerPartyMember.in_game.

member_joined

member is now in the party. When this player joins a party, it fires for every member, including this player’s own entry.

member_left

member, as last seen, is no longer in the party. When this player leaves, the snapshot becomes empty and it fires for every former member, including this player’s own entry.

search_ended

The party search in this Game reached a terminal state, or this player left the party during it.

search_started

The party leader started a party search in queue of this Game, or this player joined a party that is searching. A member follows with Summer.client.join(SummerJoinTarget.party_queue(queue)).
What is live on the platform today: platform capability status. Check availability at runtime before you offer a feature.