> For the complete documentation index, see [llms.txt](https://docs.fullscreen.no/info/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.fullscreen.no/info/standalone-assets/herobridge-standalone/troubleshooting/textmeshpro-nullreferenceexception.md).

# TextMeshPro NullReferenceException

#### Error message

```cs
NullReferenceException: Object reference not set to an instance of an object
TMPro.MaterialReference..ctor (...)
```

#### What’s causing this

The **HeroBridge Standalone** example scene uses **TextMeshPro** for UI text.\
This error happens when **TextMeshPro Essential Resources** haven’t been imported into the project.

Without these resources, TextMeshPro can’t properly initialize its materials, which results in this `NullReferenceException`.

***

#### Fix: Import TextMeshPro Essential Resources

1. Open Unity’s top menu\
   **Window → TextMeshPro → Import TMP Essential Resources**
2. Let Unity finish importing the files.
3. Close the affected scene.
4. Reopen the scene.

In most cases, this resolves the error immediately.

***

#### Don’t want to use TextMeshPro?

If you prefer not to use TextMeshPro at all, you can replace the TextMeshPro components in the example scenes with **Legacy Text UI** instead.

This avoids the dependency entirely.
