/fiveai-skills:lua-basicsfrom fiveai-skills
Writes and reviews idiomatic, performant Lua for FiveM resources. Covers naming conventions, table operations, error handling, and guard clauses.
Ships in fiveai-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Idiomatic, performant Lua patterns for FiveM: functions, tables, variables, conditionals and errors.
Load this skill when writing or reviewing any Lua in a FiveM resource, or when the user asks about Lua naming, structure, performance, tables or error handling.
ALL_CAPS constants, camelCase locals, PascalCase globals, _ for unused variables.local; declare locals as close to first use as possible; group file-level globals at the top of a single client/server file.table.insert; append with t[#t + 1] = v or maintain your own size counter.for i = 1, #t; imply array indices ({ a, b }) instead of writing them out.t.key for constant keys and t[var] for dynamic keys.if x then return true else return false end.value = value or default.assert for pre-conditions instead of if not x then error() end; fail loudly on unexpected state; return errors as values for expected failures.| Situation | Pattern |
|---|---|
| Expected failure (not found, invalid input) | return nil, err or false |
| Programmer error / impossible state | assert / error |
| Flag with more than two meanings | enum table, not boolean |
| Function reused more than once as argument | local function then pass by name |
| Append to array | t[#t + 1] = v |
if with guard clauses.table.insert and pairs on arrays with index writes and numeric loops.assert pre-conditions at function entry.Return Lua that follows the naming, locality, table and error-handling rules above; annotate any deliberate deviation.
Upstream docs: https://www.lua.org/manual/5.4/
What SKILL.md sets; muted values are Claude Code's defaults
12 skills in this plugin
/esx-frameworkTrigger: ESX, es_extended, xPlayer, PlayerData, ESX.GetPlayerFromId, ESX.RegisterServerCallback, ESX jobs, economy, inventory. Build ESX Legacy resources with server/client functions, xPlayer methods, callbacks and events./fivemanageTrigger: Fivemanage, fmsdk, takeImage, takeServerImage, uploadImage, Log, Info/Warn/Error, player screenshots, logs dashboard. Install and use the Fivemanage SDK for images and centralized logs./fivem-basicsTrigger: FiveM resource, fxmanifest, client/server script, RegisterNetEvent, TriggerServerEvent, TriggerClientEvent, exports, F8 logs, how FiveM works. Structure resources, manifests, events and exports for FiveM Lua./fivem-deploymentTrigger: server artifacts, FXServer, txAdmin, server.cfg, gamebuild, sv_enforceGameBuild, update server, deploy, EOL, recommended build. Pick, pin and deploy a supported FXServer build./fivem-nuiTrigger: NUI, ui_page, SendNUIMessage, SetNUIFocus, RegisterNUICallback, HTML/CSS/JS for FiveM, FiveM menu UI. Build FiveM NUI pages, wire Lua-browser messaging, callbacks and focus./fivem-securityTrigger: security, anti-cheat, exploit, secure events, validate client data, server authority, distance check, rate limit, review server code. Harden FiveM net events and server-side validation.npx claudepluginhub germanfndez/fiveai-skills --plugin fiveai-skillsOther plugins' skills for the same job