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

# XGameUiShowPlayerPickerResult

> XGameUiShowPlayerPickerResult

# XGameUiShowPlayerPickerResult

取得 [XGameUiShowPlayerPickerAsync](https://docs.xbox.com/zh-TW/reference/system/xgameui/functions/xgameuishowplayerpickerasync.md) 呼叫的結果。

## 語法

```cpp theme={null}
HRESULT XGameUiShowPlayerPickerResult(  
         XAsyncBlock* async,  
         uint32_t resultPlayersCount,  
         uint64_t* resultPlayers,  
         uint32_t* resultPlayersUsed  
)  
```

### 參數

*async*   \_In\_\
類型：[XAsyncBlock\*](https://docs.xbox.com/zh-TW/reference/system/xasync/structs/xasyncblock.md)

指向傳遞給 [XGameUiShowPlayerPickerAsync](https://docs.xbox.com/zh-TW/reference/system/xgameui/functions/xgameuishowplayerpickerasync.md) 之 [XAsyncBlock](https://docs.xbox.com/zh-TW/reference/system/xasync/structs/xasyncblock.md) 的指標。

*resultPlayersCount*   \_In\_\
類型：uint32\_t

玩家結果的數目，用來判斷包含結果之緩衝區的大小。您可以呼叫 [XGameUiShowPlayerPickerResultCount](https://docs.xbox.com/zh-TW/reference/system/xgameui/functions/xgameuishowplayerpickerresultcount.md) 來取得此資訊。或者，如果您已預先配置大型結果緩衝區，可以傳入等於該緩衝區可容納之 uint64\_t 欄位最大數目的數字。

*resultPlayers*   \_Out\_writes\_to\_(resultPlayersCount,*resultPlayersUsed)\
類型：uint64\_t*

指向在玩家選擇器 UI 中所選取之玩家識別碼清單的指標。

*resultPlayersUsed*   \_Out\_opt\_\
類型：uint32\_t\*

在玩家選擇器 UI 中選取的玩家數目。

### 傳回值

類型：HRESULT

HRESULT 成功或錯誤碼。

## 備註

此函式通常會在 [XGameUiShowPlayerPickerAsync](https://docs.xbox.com/zh-TW/reference/system/xgameui/functions/xgameuishowplayerpickerasync.md) 的 **XAsyncBlock** 中呼叫。此函式可讓您擷取所要求的玩家清單。您也可以呼叫 [XGameUiShowPlayerPickerResultCount](https://docs.xbox.com/zh-TW/reference/system/xgameui/functions/xgameuishowplayerpickerresultcount.md) 來取得傳回的玩家數目。\
您也可以在非同步函式完成之後隨時呼叫此函式，以擷取函式結果。

## 需求

**標頭：** XGameUI.h

**程式庫：** xgameruntime.lib

**支援的平台：** Windows、Steam Deck、XBOX One 系列主機和 XBOX Series 主機

## 另請參閱

[XGameUI](https://docs.xbox.com/zh-TW/reference/system/xgameui/xgameui_members.md)\
[XGameUiShowPlayerPickerAsync](https://docs.xbox.com/zh-TW/reference/system/xgameui/functions/xgameuishowplayerpickerasync.md)\
[XGameUiShowPlayerPickerResultCount](https://docs.xbox.com/zh-TW/reference/system/xgameui/functions/xgameuishowplayerpickerresultcount.md)


## Related topics

- [XGameUiShowPlayerPickerResultCount](https://docs.xbox.com/zh-TW/reference/system/xgameui/functions/xgameuishowplayerpickerresultcount.md)
- [XGameUiShowPlayerPickerAsync](https://docs.xbox.com/zh-TW/reference/system/xgameui/functions/xgameuishowplayerpickerasync.md)
- [XGameUiSetPlayerPickerUiResponse](https://docs.xbox.com/zh-TW/reference/system/xgameui/functions/xgameuisetplayerpickeruiresponse.md)
- [XGameUI (API 內容)](https://docs.xbox.com/zh-TW/reference/system/xgameui/xgameui_members.md)
- [XGameUiShowPlayerPickerUiCallback](https://docs.xbox.com/zh-TW/reference/system/xgameui/functions/xgameuishowplayerpickeruicallback.md)
