> ## 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.

# PFMatchmakingTicketGetStatus

> 检索 PlayFab 多人游戏匹配票证的当前状态，例如创建中、等待玩家、已匹配、已取消或失败。

提供匹配票证状态。

## 语法

```cpp theme={null}
HRESULT PFMatchmakingTicketGetStatus(  
    PFMatchmakingTicketHandle ticket,  
    PFMatchmakingTicketStatus* status  
)  
```

### 参数

**`ticket`**   PFMatchmakingTicketHandle

TBD

**`status`**   [PFMatchmakingTicketStatus\*](/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmatchmaking/enums/pfmatchmakingticketstatus)\
*output*

匹配票证状态。

### 返回值

类型：HRESULT

如果调用成功，则为 `S_OK`；否则为错误代码。可以通过 [PFMultiplayerGetErrorMessage()](/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmultiplayer/functions/pfmultiplayergeterrormessage) 获取错误代码的人类可读形式。

## 要求

**头文件：** PFMatchmaking.h

## 另请参阅

[PFMatchmaking 成员](/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmatchmaking/pfmatchmaking_members)


## Related topics

- [PFMatchmakingTicketGetMatch](/zh-CN/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmatchmaking/functions/pfmatchmakingticketgetmatch.md)
- [PFMatchmakingTicketStatusChangedStateChange](/zh-CN/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmatchmaking/structs/pfmatchmakingticketstatuschangedstatechange.md)
- [PFMultiplayerJoinMatchmakingTicketFromId](/zh-CN/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmatchmaking/functions/pfmultiplayerjoinmatchmakingticketfromid.md)
- [PFMultiplayerCreateMatchmakingTicket](/zh-CN/services/playfab/multiplayer/lobby/playfabmultiplayerreference-cpp/pfmatchmaking/functions/pfmultiplayercreatematchmakingticket.md)
- [从 MPSD 迁移到 PlayFab Multiplayer 和 MPA](/zh-CN/services/xbox-services/multiplayer/mpsd/concepts/live-mpsd-to-mlp.md)
