Class NOSModuleWrapper
MonoBehaviour wrapper for the NOS module.
Namespace: NWH.VehiclePhysics2.Modules.NOS
Assembly: NWH.VehiclePhysics2.dll
Syntax
[Serializable]
[DisallowMultipleComponent]
public class NOSModuleWrapper : ModuleWrapper
Remarks
This wrapper allows the NOSModule to be added as a component to a GameObject in the Unity Inspector. It acts as a bridge between Unity's component system and the NWH Vehicle Physics module system.
The wrapper must be added to a GameObject that already contains a VehicleController component. It automatically handles module registration and lifecycle management.
Fields
module
The wrapped NOS module instance.
Declaration
public NOSModule module
Field Value
| Type | Description |
|---|---|
| NOSModule |
Remarks
Contains all the configuration and runtime state for the NOS system. Access this property to modify NOS settings or check current state.
Methods
GetModule()
Gets the wrapped module as a VehicleComponent.
Declaration
public override VehicleComponent GetModule()
Returns
| Type | Description |
|---|---|
| VehicleComponent | The NOSModule instance cast to VehicleComponent |
Overrides
Remarks
Used by the module system for generic module handling and lifecycle management.
SetModule(VehicleComponent)
Sets the wrapped module from a VehicleComponent reference.
Declaration
public override void SetModule(VehicleComponent module)
Parameters
| Type | Name | Description |
|---|---|---|
| VehicleComponent | module | The VehicleComponent to wrap, must be a NOSModule instance |
Overrides
Remarks
Used by the module system when dynamically creating or replacing modules. The provided module must be castable to NOSModule.