# ControllerPartSensor

Roblox Engine API class from Roblox Studio 0.744.0.7441077 (version-7aaa6838d36c4448).

- Inherits from, nearest first: [ControllerSensor](https://rapi.sleaze.dev/classes/ControllerSensor.md), [SensorBase](https://rapi.sleaze.dev/classes/SensorBase.md), [Instance](https://rapi.sleaze.dev/classes/Instance.md), [Object](https://rapi.sleaze.dev/classes/Object.md)
- Memory category: Instances
- HTML page: https://rapi.sleaze.dev/classes/ControllerPartSensor/
- Roblox documentation: https://create.roblox.com/docs/reference/engine/classes/ControllerPartSensor

A [`SensorBase`](https://rapi.sleaze.dev/classes/SensorBase.md) that outputs data about another [`BasePart`](https://rapi.sleaze.dev/classes/BasePart.md) based on [`Humanoid`](https://rapi.sleaze.dev/classes/Humanoid.md) floor and ladder detection logic.

## Properties

### SensedMaterial

```luau
ControllerPartSensor.SensedMaterial: Enum.Material = Enum.Material.Air
```

- Tags: Capabilities: Basic, Simulation access

The surface `Material` of the [`ControllerPartSensor.SensedPart`](https://rapi.sleaze.dev/classes/ControllerPartSensor.md) that the sensor is currently detecting.

### LadderSearchHeight

```luau
ControllerPartSensor.LadderSearchHeight: number = 6
```

- Tags: Capabilities: Basic, Simulation access

The upper bound, in studs, of the vertical region the sensor searches for a ladder when [`ControllerPartSensor.SensorMode`](https://rapi.sleaze.dev/classes/ControllerPartSensor.md) is set to a ladder mode.

### LadderSearchOffset

```luau
ControllerPartSensor.LadderSearchOffset: number = 5
```

- Tags: Capabilities: Basic, Simulation access

The downward offset, in studs, that positions the vertical region the sensor searches for a ladder when [`ControllerPartSensor.SensorMode`](https://rapi.sleaze.dev/classes/ControllerPartSensor.md) is set to a ladder mode.

### SearchDistance

```luau
ControllerPartSensor.SearchDistance: number = 0
```

- Tags: Read capabilities: Basic, Simulation access

The distance from the sensor's parent [`BasePart`](https://rapi.sleaze.dev/classes/BasePart.md) to use when sensing other parts.

### SensorMode

```luau
ControllerPartSensor.SensorMode: Enum.SensorMode = Enum.SensorMode.Floor
```

- Tags: Read capabilities: Basic, Simulation access

Determines what behavior this [`SensorBase`](https://rapi.sleaze.dev/classes/SensorBase.md) uses when sensing other parts.

### HitFrame

```luau
ControllerPartSensor.HitFrame: CFrame = CFrame.identity
```

- Tags: Read capabilities: Basic, Simulation access

The position in world space where the sensor hit the [`ControllerPartSensor.SensedPart`](https://rapi.sleaze.dev/classes/ControllerPartSensor.md).

### HitNormal

```luau
ControllerPartSensor.HitNormal: Vector3 = Vector3.new(0, 1, 0)
```

- Tags: Read capabilities: Basic, Simulation access

The surface normal at the position where the sensor hit the [`ControllerPartSensor.SensedPart`](https://rapi.sleaze.dev/classes/ControllerPartSensor.md).

### SensedPart

```luau
ControllerPartSensor.SensedPart: BasePart
```

- Tags: Read capabilities: Basic, Simulation access

A reference to the [`BasePart`](https://rapi.sleaze.dev/classes/BasePart.md) hit by the sensor.

## Inherited members

- From [SensorBase](https://rapi.sleaze.dev/classes/SensorBase.md): `UpdateType`, `Sense`, `OnSensorOutputChanged`
- From [Instance](https://rapi.sleaze.dev/classes/Instance.md): `Archivable`, `archivable`, `Attributes`, `AttributesReplicate`, `AttributesSerialize`, `HistoryId`, `Name`, `Parent`, `PredictionMode`, `PropertyStatusStudio`, `RobloxLocked`, `SerializedOverrides`, `SourceAssetId`, `Tags`, `UniqueId`, `numExpectedDirectChildren`, `DataCost`, `Capabilities`, `DefinesCapabilities`, `IsInSandbox`, `Sandboxed`, `AddTag`, `ClearAllChildren`, `Clone`, `Destroy`, `FindFirstAncestor`, `FindFirstAncestorOfClass`, `FindFirstAncestorWhichIsA`, `FindFirstChild`, `FindFirstChildOfClass`, `FindFirstChildWhichIsA`, `FindFirstDescendant`, `GetActor`, `GetAttribute`, `GetAttributeChangedSignal`, `GetAttributes`, `GetChildren`, `GetDebugId`, `GetDescendants`, `GetFullName`, `GetStyled`, `GetStyledPropertyChangedSignal`, `GetTags`, `HasTag`, `IsAncestorOf`, `IsDescendantOf`, `IsPropertyModified`, `QueryDescendants`, `RemoveTag`, `ResetPropertyToDefault`, `SetAttribute`, `WaitForChild`, `Remove`, `children`, `clone`, `destroy`, `findFirstChild`, `getChildren`, `isDescendantOf`, `remove`, `AncestryChanged`, `AttributeChanged`, `ChildAdded`, `ChildRemoved`, `DescendantAdded`, `DescendantRemoving`, `Destroying`, `StyledPropertiesChanged`, `childAdded`
- From [Object](https://rapi.sleaze.dev/classes/Object.md): `ClassName`, `className`, `GetPropertyChangedSignal`, `IsA`, `isA`, `Changed`
