openMenuFor
Opens one of this resource's menus on a specific player, with that menu's ordinary rules intact.
💡 Syntax
local ok, err = exports['kartik-clothing']:openMenuFor(target, kind)📥 Parameters
| Parameter | Type | Optional | Description |
|---|---|---|---|
target | number | No | Server ID of the player. |
kind | string | Yes | Which menu to open. Defaults to clothing. |
Menu kinds
| Kind | Opens |
|---|---|
clothing · apparel | Clothing store |
barber · hair | Barber & hair studio |
tattoos | Tattoo parlour |
wardrobe | Saved outfits |
ped | Ped Changer |
creator | Full character creator |
studio | Custom garment design studio |
📤 Returns
| Type | Description |
|---|---|
boolean | true if the menu was opened. |
string? | Error code when it was not: no_player or unknown_menu. |
📝 Example
exports['kartik-clothing']:openMenuFor(playerId, 'barber')[!WARNING]
pedstill runs the player's ownConfig.PedShopOwnersOnlycheck and is refused for a player who owns nothing. To edit a body regardless of what they own, usegrantSurgery, which waives the catalogue rather than enforcing it.
[!NOTE] The caller is not checked. A server export is already inside the trust boundary, the resource calling it decides who is allowed to.