> 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.client.unity.editor/ks.reactor.client.unity.editor.ksserverprojectwatcher.md).

# Class ksServerProjectWatcher

Namespace: [KS.Reactor.Client.Unity.Editor](/reactor/api-reference/ks.reactor.client.unity.editor.md)\
Assembly: KSUnity-Source.dll

Monitors the server runtime project. If it detects changes in .cs files, it will build the project when Unity has focus.

```csharp
public class ksServerProjectWatcher : ksSingleton<ksServerProjectWatcher>
```

#### Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) ← Object ← ScriptableObject ← [ksSingleton\<ksServerProjectWatcher>](/reactor/api-reference/ks.unity.editor/ks.unity.editor.kssingleton-1.md) ← [ksServerProjectWatcher](/reactor/api-reference/ks.reactor.client.unity.editor/ks.reactor.client.unity.editor.ksserverprojectwatcher.md)

#### Inherited Members

[ksSingleton\<ksServerProjectWatcher>.Get()](/reactor/api-reference/ks.unity.editor/ks.unity.editor.kssingleton-1.md#KS_Unity_Editor_ksSingleton_1_Get), [ksSingleton\<ksServerProjectWatcher>.Initialize()](/reactor/api-reference/ks.unity.editor/ks.unity.editor.kssingleton-1.md#KS_Unity_Editor_ksSingleton_1_Initialize), [ksSingleton\<ksServerProjectWatcher>.Create()](/reactor/api-reference/ks.unity.editor/ks.unity.editor.kssingleton-1.md#KS_Unity_Editor_ksSingleton_1_Create), ScriptableObject.SetDirty(), ScriptableObject.CreateInstance(string), ScriptableObject.CreateInstance(Type), ScriptableObject.CreateInstance\<T>(), Object.GetInstanceID(), Object.GetHashCode(), Object.Equals(object), Object.Instantiate(Object, Vector3, Quaternion), Object.Instantiate(Object, Vector3, Quaternion, Transform), Object.Instantiate(Object), Object.Instantiate(Object, Transform), Object.Instantiate(Object, Transform, bool), Object.Instantiate\<T>(T), Object.Instantiate\<T>(T, Vector3, Quaternion), Object.Instantiate\<T>(T, Vector3, Quaternion, Transform), Object.Instantiate\<T>(T, Transform), Object.Instantiate\<T>(T, Transform, bool), Object.Destroy(Object, float), Object.Destroy(Object), Object.DestroyImmediate(Object, bool), Object.DestroyImmediate(Object), Object.FindObjectsOfType(Type), Object.FindObjectsOfType(Type, bool), Object.FindObjectsByType(Type, FindObjectsSortMode), Object.FindObjectsByType(Type, FindObjectsInactive, FindObjectsSortMode), Object.DontDestroyOnLoad(Object), Object.DestroyObject(Object, float), Object.DestroyObject(Object), Object.FindSceneObjectsOfType(Type), Object.FindObjectsOfTypeIncludingAssets(Type), Object.FindObjectsOfType\<T>(), Object.FindObjectsByType\<T>(FindObjectsSortMode), Object.FindObjectsOfType\<T>(bool), Object.FindObjectsByType\<T>(FindObjectsInactive, FindObjectsSortMode), Object.FindObjectOfType\<T>(), Object.FindObjectOfType\<T>(bool), Object.FindFirstObjectByType\<T>(), Object.FindAnyObjectByType\<T>(), Object.FindFirstObjectByType\<T>(FindObjectsInactive), Object.FindAnyObjectByType\<T>(FindObjectsInactive), Object.FindObjectsOfTypeAll(Type), Object.FindObjectOfType(Type), Object.FindFirstObjectByType(Type), Object.FindAnyObjectByType(Type), Object.FindObjectOfType(Type, bool), Object.FindFirstObjectByType(Type, FindObjectsInactive), Object.FindAnyObjectByType(Type, FindObjectsInactive), Object.ToString(), Object.name, Object.hideFlags, [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.MemberwiseClone()](https://learn.microsoft.com/dotnet/api/system.object.memberwiseclone), [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

### RequiresServerBuild <a href="#ks_reactor_client_unity_editor_ksserverprojectwatcher_requiresserverbuild" id="ks_reactor_client_unity_editor_ksserverprojectwatcher_requiresserverbuild"></a>

Was the server project modified since the last server project build?

```csharp
public bool RequiresServerBuild { get; set; }
```

#### Property Value

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

## Methods

### Ignore(string) <a href="#ks_reactor_client_unity_editor_ksserverprojectwatcher_ignore_system_string" id="ks_reactor_client_unity_editor_ksserverprojectwatcher_ignore_system_string"></a>

Tells the watcher to ignore the next event from a given path.

```csharp
public void Ignore(string path)
```

#### Parameters

`path` [string](https://learn.microsoft.com/dotnet/api/system.string)

Path to ignore next event from.

### OnDisable() <a href="#ks_reactor_client_unity_editor_ksserverprojectwatcher_ondisable" id="ks_reactor_client_unity_editor_ksserverprojectwatcher_ondisable"></a>

Serializes rename data so it persists across recompiles/play mode.

```csharp
public void OnDisable()
```

### Run() <a href="#ks_reactor_client_unity_editor_ksserverprojectwatcher_run" id="ks_reactor_client_unity_editor_ksserverprojectwatcher_run"></a>

Begins monitoring the server runtime project. Builds the server project if Unity just started up.

```csharp
public void Run()
```
