# Random Selector

### Description

Executes child nodes in turn, but if one of them returns success, running, or aborted, it completes execution and returns this value, otherwise, if all return failure, it returns failure to the parent node.&#x20;

The difference from the usual Selector is that at the beginning it randomly sorts child objects and then executes them.

**To create it**, right-click in the editor and select <mark style="color:purple;">Create Node/Composites/Random Selector</mark>.

<figure><img src="/files/V9CooQR8rcI6VaJMXkFS" alt=""><figcaption></figcaption></figure>


---

# 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://renownedgames.gitbook.io/ai-tree/nodes/composite/selector/random-selector.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.
