跳轉到主要內容
已淘汰。 此方法已在 GameInput v4 中移除,目前的 API 中無法使用。請改用 IGameInputDevice::IsConnected 檢查裝置是否已連線,並在裝置回呼中處理 GameInputDeviceEvent 值以回應變更。
擷取輸入裝置目前的狀態。

語法

參數

此方法沒有參數。

傳回值

類型:GameInputDeviceStatus 傳回的值是列舉類型 GameInputDeviceStatus。傳回的值可能是 GameInputDeviceStatus 中列舉旗標值的組合。

備註

傳回的 GameInputDeviceStatus 列舉會定義裝置是否已連線,以及遊戲與裝置之間可傳輸的輸入和輸出類型。如果在裝置已從系統中斷連線時呼叫 GetDeviceStatus 方法,則會傳回 GameInputDeviceNoStatus 值。您可以將 GameInputDeviceStatus 列舉當作 RegisterDeviceCallback 方法的篩選條件,以回應裝置狀態的特定變更。

需求

標頭: GameInput.h

另請參閱

已淘汰的 GameInput API 成員
IGameInputDevice::IsConnected
GameInputDeviceEvent
GameInput 概觀
GameInputDeviceStatus
RegisterDeviceCallback
IGameInputDevice

版本歷程記錄

最後修改於 2026年11月6日