---
title: GCControllerButtonValueChangedHandler
framework: gamecontroller
role: symbol
role_heading: Type Alias
path: gamecontroller/gccontrollerbuttonvaluechangedhandler
---

# GCControllerButtonValueChangedHandler

The signature for the block that executes when a button’s state changes.

## Declaration

```swift
typealias GCControllerButtonValueChangedHandler = (GCControllerButtonInput, Float, Bool) -> Void
```

## Parameters

- `button`: The button element whose state changed.
- `value`: A normalized number between 0.0 (minimum) and 1.0 (maximum) that represents the amount of physical or simulated pressure that the user applies to the button.
- `pressed`: A Boolean value that indicates whether the user is pressing the button. If doc://com.apple.documentation/documentation/Swift/true, the user is pressing the button and the value parameter contains the amount of pressure. If doc://com.apple.documentation/documentation/Swift/false, the user isn’t applying any pressure and the value parameter is 0.0.

## See Also

### Getting change information

- [touchedChangedHandler](gamecontroller/gccontrollerbuttoninput/touchedchangedhandler.md)
- [GCControllerButtonTouchedChangedHandler](gamecontroller/gccontrollerbuttontouchedchangedhandler.md)
- [pressedChangedHandler](gamecontroller/gccontrollerbuttoninput/pressedchangedhandler.md)
- [valueChangedHandler](gamecontroller/gccontrollerbuttoninput/valuechangedhandler.md)
