PUBLIC LUA EXAMPLES

Nenyoo Lua Menu Starter

Download an editable Lua menu example with a nested page, actions, a toggle and local counter. Learn the native Nenyoo menu builder without changing game state.

GTA V PremiumNative Engine + Foundation APINenyoo documentation examples

What this example does

The @nenyoo-menu marker makes the file an expandable script page. menu.my_root returns its root and menu.list adds a child page.

Actions change a local Lua variable. The toggle controls notifications; it does not enable a gameplay feature. print also writes a message for the Lua console.

Rename the labels and replace the action body when building your own utility. Keep commands in the empty command tables until you intend to expose named commands.

Install and run

  1. Use Nenyoo GTA V Premium with the native Lua API. Download the file and keep its .lua extension.
  2. Put nenyoo-menu-starter.lua in the native user-script folder:%LOCALAPPDATA%\Nenyoo\Plus\Scripts\User\
  3. Refresh the script list, load the script, and open its script page. Keep the -- @nenyoo-menu marker at the top.
  4. Use the script’s Unload action when finished. Reload after editing its source.

Try it

  1. Open the script page, enter Counter and choose Add one twice.
  2. Turn Show notifications off, then use Add one again. The console message remains, while the toast is skipped.
  3. Choose Reset counter. Reloading or unloading also discards the local state.

Complete Lua source

nenyoo-menu-starter.lua · original Nenyoo documentation example

-- @nenyoo-menu -- Nenyoo documentation example: menu starter. -- Requires GTA V Premium's native Engine + Foundation Lua APIs. -- Source review only; no in-game compatibility claim. local root = menu.my_root() local counter = 0 local show_notifications = true menu.toggle(root, "Show notifications", {}, "Local script preference", function(on) show_notifications = on end, true) local counter_page = menu.list(root, "Counter", {}, "Practice actions and local state") menu.action(counter_page, "Add one", {}, "Increment the local counter", function() counter = counter + 1 print("Documentation counter: " .. counter) if show_notifications then util.toast("Counter: " .. counter) end end) menu.action(counter_page, "Reset counter", {}, "Reset this script's counter", function() counter = 0 print("Documentation counter reset") if show_notifications then util.toast("Counter reset") end end)

Requirements and limits

  • The counter and preference exist only while the script is loaded; this example does not save a configuration.
  • This is a native Engine + Foundation example, not a Stand script. Install it in User, not User/stand.

API and source review: 2026-11-13. These examples were reviewed against the bundled Nenyoo reference and source. They have not been tested in a running game, and no particular game-build compatibility is claimed.

APIs used: menu.my_root, menu.toggle, menu.list, menu.action, util.toast

More Lua examples