Skip to main content

Server Functions

Functions available on the server side. Import the core in your resource's fxmanifest.lua and call them through the global MSK table (or via exports.msk_core:*):

shared_script '@msk_core/import.lua'

Overview

PageDescription
PlayerPlayer getters (GetPlayer, GetPlayers, …) and the mirrored table
InventoryMSK.HasItem, MSK.RegisterItem and the inventory bridge
EntitiesClosest entity/player helpers
VehicleServer-side vehicle queries
CoordsShow / copy coordinates for a player
WorldSpawn-point checks, closest players, MSK.AddWebhook
NotifySend notifications to a player by server id
ScaleformTrigger scaleforms on a player
Ace PermissionAce checks, AddAce / AddPrincipal
CommandsMSK.RegisterCommand with ace restriction
SocietyCompany / society account money
OfflineOffline player bank money
Ban SystemIdentifier/token bans and ban commands
CronSchedule recurring jobs
Disconnect LoggerLog player disconnects
Version CheckerMSK.Check version & dependency checks
UIServer-side Input, Numpad, Progressbar, TextUI

See also the Shared functions (callbacks, math, string, table, timeout, vector) which work on both sides.