---
title: nextInputState()
framework: gamecontroller
role: symbol
role_heading: Instance Method
path: gamecontroller/gccontrollerliveinput/nextinputstate()
---

# nextInputState()

Returns the next device input state from the queue.

## Declaration

```swift
func nextInputState() -> (any GCControllerInputState & GCDevicePhysicalInputStateDiff)?
```

## Return Value

Return Value The next input state in the queue or nil if the queue is empty.

## See Also

### Handling device input

- [capture()](gamecontroller/gccontrollerliveinput/capture().md)
