> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# PFMatchmakingTicketSetCustomContext

> アプリケーションが後から取得できるように、PlayFab Multiplayer マッチメイキング チケットにオプションのポインター サイズのカスタム コンテキスト値を関連付けます。

このチケット オブジェクトに、オプションのカスタム ポインター サイズのコンテキスト値を構成します。

## 構文

```cpp theme={null}
HRESULT PFMatchmakingTicketSetCustomContext(  
    PFMatchmakingTicketHandle ticket,  
    void* customContext  
)  
```

### パラメーター

**`ticket`**   PFMatchmakingTicketHandle

マッチメイキング チケットのハンドルです。

**`customContext`**   void\*\
*省略可能*

プレイヤー オブジェクトと共に格納する、任意のポインター サイズの値です。

### 戻り値

型: HRESULT

カスタム コンテキストの構成が成功した場合は `S_OK`、それ以外の場合はエラー コード。エラー コードを人間が読める形式で取得するには、[PFMultiplayerGetErrorMessage()](/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmultiplayer/functions/pfmultiplayergeterrormessage) を使用します。

\u0001\u0001\u0001## 解説

カスタム コンテキストは通常、マッピングの参照を必要とせずにマッチメイキング チケットに関連付けられたローカルなタイトル固有のメモリへのアクセスを簡略化する "ショートカット" として使用されます。値は [PFMatchmakingTicketGetCustomContext()](/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmatchmaking/functions/pfmatchmakingticketgetcustomcontext) メソッドを使用して取得します。<br /><br /> 構成された値はライブラリからは不透明として扱われ、ローカル デバイスでのみ有効です。ネットワークを介して送信されることはありません。

## 要件

**ヘッダー:** PFMatchmaking.h

## 関連項目

[PFMatchmaking のメンバー](/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmatchmaking/pfmatchmaking_members)\
[PFMatchmakingTicketGetCustomContext](/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmatchmaking/functions/pfmatchmakingticketgetcustomcontext)


## Related topics

- [PFMatchmakingTicketGetCustomContext](/ja-jp/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmatchmaking/functions/pfmatchmakingticketgetcustomcontext.md)
- [PlayFab Multiplayer C++ SDK リリース ノート](/ja-jp/services/playfab/multiplayer/lobby/lobby-matchmaking-sdks/lobby-and-matchmaking-release-notes.md)
- [PFMultiplayer C/C++ API overview - PFMatchmaking.h](/ja-jp/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmatchmaking/pfmatchmaking_members.md)
- [XblMatchmakingCreateMatchTicketAsync](/ja-jp/reference/live/xsapi-c/matchmaking_c/functions/xblmatchmakingcreatematchticketasync.md)
- [XblMatchmakingDeleteMatchTicketAsync](/ja-jp/reference/live/xsapi-c/matchmaking_c/functions/xblmatchmakingdeletematchticketasync.md)
