# WriteUShort(ushort)

> Writes a 2-byte unsigned short to the current stream and advances the stream position by two bytes.

## Definition

* **Type:** Method
* **Namespace:** [Unity.Collections](/engine/6000.7/script-reference/unity/collections.md)
* **Assembly:** UnityEngine.ManagedKernelModule

```csharp
public bool WriteUShort(ushort value)
```

### Parameters

**** (\[ushort]\(https\://learn.microsoft.com/dotnet/api/system.uint16)): The 2-byte unsigned short to write.

### Returns

| Type                                                          | Description                      |
| ------------------------------------------------------------- | -------------------------------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) | Whether the write was successful |
