# LiveQuery

### LiveQuery

The way you get information about the World is through **LiveQueries**. We set criteria for what part of the World we are interested in at each given moment. That way, the Replicator won’t send information about everything that is going on in the Game World everywhere, at all times.

Instead, we will just get information about what’s within a certain area, kind of like moving a torch to look around in a dark cave.

{% hint style="info" %}
More complex areas of interest types are coming in future versions of **coherence**.
{% endhint %}

### Adding a LiveQuery to the scene

![](https://3798176112-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FZcBSvjNQZSas5L9C0K8K%2Fuploads%2FcZ4WK99tbOOUQgdvnh0X%2Fimage.png?alt=media)

A LiveQuery is a cube that defines the area of interest in a particular part of the world. It is defined by its **position** and its **extent** (half the side of the cube). There can be multiple LiveQueries in a single scene.

![](https://3798176112-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FZcBSvjNQZSas5L9C0K8K%2Fuploads%2F9ubI3GO64jB75XNXZdEK%2Fimage.png?alt=media)

### Moving a LiveQuery

The classic approach is to put a LiveQuery on the camera and set the extent to correspond to the far clipping plane or visibility distance.

Moving the GameObject containing the LiveQuery will also notify the Replication Server that the query for that particular Game Client has moved.


---

# Agent Instructions: 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:

```
GET https://docs.coherence.io/0.9/api-reference/network-sdk/livequery.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
