> For the complete documentation index, see [llms.txt](https://fish-networking.gitbook.io/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://fish-networking.gitbook.io/docs/fishnet-building-blocks/components/network-behaviour-components.md).

# NetworkBehaviour

## Description

NetworkBehaviour(s) cannot be added to objects directly. This script must be inherited from before it may be included on an object. Inheriting from NetworkBehaviour allows access to [network communications](/docs/guides/high-level-overview/terminology/communicating.md) and other useful data about the network, server, and client.

Each NetworkBehaviour must be attached to a GameObject that also has a NetworkObject component on it or one of its parent objects.

{% hint style="danger" %}
Adding a NetworkBehaviour derived component at run-time is not yet supported.
{% endhint %}

Please check out the guide page for more information about all the things you can do with NetworkBehaviours:

<table data-view="cards"><thead><tr><th align="center"></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td align="center"><span data-gb-custom-inline data-tag="emoji" data-code="1f4d8">📘</span> <mark style="color:blue;">NetworkBehaviour Guide</mark></td><td><a href="/pages/ftAnTUrpqYOrKMe1kikV">/pages/ftAnTUrpqYOrKMe1kikV</a></td></tr><tr><td align="center">🔌 <mark style="color:yellow;">NetworkBehaviour API</mark></td><td><a href="https://fish-networking.com/FishNet/api/api/FishNet.Object.NetworkBehaviour.html">https://fish-networking.com/FishNet/api/api/FishNet.Object.NetworkBehaviour.html</a></td></tr></tbody></table>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://fish-networking.gitbook.io/docs/fishnet-building-blocks/components/network-behaviour-components.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
