> For the complete documentation index, see [llms.txt](https://docs.coherence.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.coherence.io/0.9/tutorial-project/network-playground/network-commands.md).

# 6. Network commands

## Sending network commands

This scene will show you how easy it is to set up Networking in your Unity project and send network commands to other Clients. Network commands are like sending direct messages to objects instead of syncing variable values.

In this example each Client has one character they can control with "click to move" input. They can right-click on another Entity to send a command and that Entity will instantiate an Exclamation mark above their head.

![](/files/-MWdmQpA-j_3Eflk-e7J)

### General setup

In the *Hierarchy* of the scene you can see three core Prefabs:

`Core Scene Setup` and `Coherence Setup` are present in all scenes and described in detail on [Start Tutorial](/0.9/tutorial-project/network-playground.md) page.

`Coherence Entity` is the Prefab that will change per scene with different functionality. It has a standard `CharacterController`and `Rigidbody` as well as an `Agent` script which will handle movement functionality through the `Input Manager` in the `Core Scene Setup` Prefab.

### In this scene...

`Coherence Entity` can send commands to other entities through the `Coherence Handler` component. In the coherenceSync component we can open the bindings window and find a `Methods` tab used for command setup. There we can find a method called `ReceiveCommand` and beside it, an icon describing who the command will be sent to (only to the objects' authority or alternatively to all Clients).

In the game view in Play mode, commands can be sent to other Entities via the right click button. An exclamation mark asset will pop up above the right-clicked Entity for all Clients.

If we were to set this command to `Authority Only` then only the objects' authority would receive this method call.

![](/files/FyJfXCZaLKXqnxHDl4Y6)

### Build and try

You can build this scene via the *Build Settings*. Run the local Replication Server through the *Window > Coherence > Settings* window and see how it works. You can try running multiple Clients rather than just two and see how replication works for each.


---

# 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://docs.coherence.io/0.9/tutorial-project/network-playground/network-commands.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.
