game_chat_communication_relationship_adjuster_changed_state_change

Represents information specific to the game_chat_state_change_type::communication_relationship_adjuster_changed state change.

Syntax

typedef struct game_chat_communication_relationship_adjuster_changed_state_change {  
    chat_user* local_user;  
    chat_user* target_user;  
} game_chat_communication_relationship_adjuster_changed_state_change  

Members

local_user  
Type: chat_user*

A pointer to the chat_user object that represents the local user on which the relationship is based.

Pointers for chat_user objects remain valid until the user has been removed from the local chat_manager instance via the chat_manager::remove_user method.

target_user  
Type: chat_user*

A pointer to the chat_user object that represents the target user in the relationship. This user could be either local or remote.

Remarks

This structure provides additional information for a game_chat_state_change_type::text_chat_received state change in Game Chat 2. This state change occurs when a local user's communication relationship adjuster with respect to another user has changed. This state change can occur under the following conditions:

  • A communication relationship between a particular pair of users has been set for the first time; the adjuster is expected to move into the initializing state.
  • The adjuster has finished initializing.
  • The adjuster has changed due to action by the user; for example, a privacy relationship has changed.

To determine the effective communication relationship and the adjuster that is applied, call the chat_user_local::get_effective_communication_relationship method, as illustrated in the following code example.

game_chat_communication_relationship_flags effectiveRelationship;
game_chat_communication_relationship_adjuster adjuster; 
local_user->get_effective_communication_relationship(target_user, &effectiveRelationship, &adjuster);

If this state change occurs, this structure is returned as a game_chat_state_change element in the game_chat_state_change_array array retrieved when chat_manager::start_processing_state_changes is called by your app. After confirming the state change type by checking the value of the state_change_type member for that game_chat_state_change element, you can then cast that element to this structure. You can then use this structure to obtain more information about and process the state change before the array is passed back to Game Chat 2 from your app, by calling chat_manager::finish_processing_state_changes.

For more information about processing state changes, see Using the Game Chat 2 C++ API.

Requirements

Header: GameChat2.h

Supported platforms: Windows, Xbox One family consoles and Xbox Series consoles

See also

Intro to Game Chat 2
chat_manager
chat_user_local::set_communication_relationship
game_chat_communication_relationship_adjuster
GameChat2 members