> For the complete documentation index, see [llms.txt](https://kinematicsoup.gitbook.io/reactor/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://kinematicsoup.gitbook.io/reactor/api-reference/ks.reactor/ks.reactor.ksraycastresult.md).

# Struct ksRaycastResult

Namespace: [KS.Reactor](/reactor/api-reference/ks.reactor.md)\
Assembly: KSCommon.dll

Result of an raycast scene query.

```csharp
public struct ksRaycastResult : ksIQueryHitResult
```

#### Implements

[ksIQueryHitResult](/reactor/api-reference/ks.reactor/ks.reactor.ksiqueryhitresult.md)

#### Inherited Members

[object.Equals(object)](https://learn.microsoft.com/dotnet/api/system.object.equals#system-object-equals\(system-object\)), [object.Equals(object, object)](https://learn.microsoft.com/dotnet/api/system.object.equals#system-object-equals\(system-object-system-object\)), [object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode), [object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype), [object.ReferenceEquals(object, object)](https://learn.microsoft.com/dotnet/api/system.object.referenceequals), [object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)

## Properties

### Collider <a href="#ks_reactor_ksraycastresult_collider" id="ks_reactor_ksraycastresult_collider"></a>

Collider hit by the raycast.

```csharp
public ksICollider Collider { readonly get; set; }
```

#### Property Value

[ksICollider](/reactor/api-reference/ks.reactor/ks.reactor.ksicollider.md)

### Distance <a href="#ks_reactor_ksraycastresult_distance" id="ks_reactor_ksraycastresult_distance"></a>

Distance along the raycast when the intersection was detected.

```csharp
public float Distance { readonly get; set; }
```

#### Property Value

[float](https://learn.microsoft.com/dotnet/api/system.single)

### Entity <a href="#ks_reactor_ksraycastresult_entity" id="ks_reactor_ksraycastresult_entity"></a>

Entity hit by the raycast.

```csharp
public ksIEntity Entity { readonly get; set; }
```

#### Property Value

[ksIEntity](/reactor/api-reference/ks.reactor/ks.reactor.ksientity.md)

### IsInitialOverlap <a href="#ks_reactor_ksraycastresult_isinitialoverlap" id="ks_reactor_ksraycastresult_isinitialoverlap"></a>

Is the entity/collider overlapping with the raycast origin?

```csharp
public bool IsInitialOverlap { get; }
```

#### Property Value

[bool](https://learn.microsoft.com/dotnet/api/system.boolean)

### IsValid <a href="#ks_reactor_ksraycastresult_isvalid" id="ks_reactor_ksraycastresult_isvalid"></a>

A raycast result is only valid if it includes an entity reference.

```csharp
public bool IsValid { get; }
```

#### Property Value

[bool](https://learn.microsoft.com/dotnet/api/system.boolean)

### Normal <a href="#ks_reactor_ksraycastresult_normal" id="ks_reactor_ksraycastresult_normal"></a>

Normal of the surface where the raycast point is.

```csharp
public ksVector3 Normal { readonly get; set; }
```

#### Property Value

[ksVector3](/reactor/api-reference/ks.reactor/ks.reactor.ksvector3.md)

### Point <a href="#ks_reactor_ksraycastresult_point" id="ks_reactor_ksraycastresult_point"></a>

Point on the surface of the entity where the ray instersected

```csharp
public ksVector3 Point { readonly get; set; }
```

#### Property Value

[ksVector3](/reactor/api-reference/ks.reactor/ks.reactor.ksvector3.md)
