---
title: GCMouse
framework: gamecontroller
role: symbol
role_heading: Class
path: gamecontroller/gcmouse
---

# GCMouse

An object that represents a physical mouse connected to a device.

## Declaration

```swift
class GCMouse
```

## Overview

Overview To get a mouse object and its input values, register for the GCMouseDidConnect (Swift) or GCMouseDidConnectNotification (Objective-C) notification for when a mouse connects to the device. Then register for the GCMouseDidBecomeCurrent  (Swift) or GCMouseDidBecomeCurrentNotification (Objective-C) notification for when it becomes the current mouse. Alternatively, use the current class property or the mice() class method to get a mouse object. Then get the current input values from the mouse object’s mouseInput controller profile.

## Topics

### Discovering mouse devices

- [mice()](gamecontroller/gcmouse/mice().md)
- [GCMouseDidConnect](foundation/nsnotification/name-swift.struct/gcmousedidconnect.md)
- [GCMouseDidDisconnect](foundation/nsnotification/name-swift.struct/gcmousediddisconnect.md)

### Handling multiple mouse devices

- [current](gamecontroller/gcmouse/current.md)
- [GCMouseDidBecomeCurrent](foundation/nsnotification/name-swift.struct/gcmousedidbecomecurrent.md)
- [GCMouseDidStopBeingCurrent](foundation/nsnotification/name-swift.struct/gcmousedidstopbeingcurrent.md)

### Getting input values

- [mouseInput](gamecontroller/gcmouse/mouseinput.md)

### Structures

- [GCMouse.DidBecomeCurrentMessage](gamecontroller/gcmouse/didbecomecurrentmessage.md)
- [GCMouse.DidConnectMessage](gamecontroller/gcmouse/didconnectmessage.md)
- [GCMouse.DidDisconnectMessage](gamecontroller/gcmouse/diddisconnectmessage.md)
- [GCMouse.DidStopBeingCurrentMessage](gamecontroller/gcmouse/didstopbeingcurrentmessage.md)

## Relationships

### Inherits From

- [NSObject](objectivec/nsobject-swift.class.md)

### Conforms To

- [CVarArg](swift/cvararg.md)
- [CustomDebugStringConvertible](swift/customdebugstringconvertible.md)
- [CustomStringConvertible](swift/customstringconvertible.md)
- [Equatable](swift/equatable.md)
- [GCDevice](gamecontroller/gcdevice.md)
- [Hashable](swift/hashable.md)
- [NSObjectProtocol](objectivec/nsobjectprotocol.md)

## See Also

### Game controllers

- [Supporting Game Controllers](gamecontroller/supporting-game-controllers.md)
- [Letting players use their second-generation Siri Remote as a game controller](gamecontroller/letting-players-use-their-second-generation-siri-remote-as-a-game-controller.md)
- [Discovering and tracking spatial game controllers and styli](gamecontroller/discovering-and-tracking-spatial-game-controllers-and-styli.md)
- [GCDevice](gamecontroller/gcdevice.md)
- [GCController](gamecontroller/gccontroller.md)
- [GCRacingWheel](gamecontroller/gcracingwheel.md)
- [GCKeyboard](gamecontroller/gckeyboard.md)
- [GCStylus](gamecontroller/gcstylus.md)
