# g\_util

- [yield](https://docs.cherax.vip/lua-documentation/api-reference/g_util/yield.md): If executed within scripting thread, the thread will be paused for the given time.
- [is\_session\_started](https://docs.cherax.vip/lua-documentation/api-reference/g_util/is_session_started.md): Returns whether the player is in an online session or not.
- [get\_selected\_player](https://docs.cherax.vip/lua-documentation/api-reference/g_util/get_selected_player.md): Returns the current selected player in the player list of the menu.
- [trigger\_script\_event](https://docs.cherax.vip/lua-documentation/api-reference/g_util/trigger_script_event.md)
- [get\_menu\_version](https://docs.cherax.vip/lua-documentation/api-reference/g_util/get_menu_version.md): Returns the current menu version.
- [joaat](https://docs.cherax.vip/lua-documentation/api-reference/g_util/joaat.md)
- [play\_wav\_file](https://docs.cherax.vip/lua-documentation/api-reference/g_util/play_wav_file.md)


---

# 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.cherax.vip/lua-documentation/api-reference/g_util.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.
