Skip to main content

v3.3.0

Added

  • MSK.AddRawAce and MSK.RemoveRawAce, for ace objects that must not live under command.. MSK.AddAce prefixes every ace with command., which is right for commands and wrong for anything used as a permission object. Ace objects are inherited by their children and almost every server.cfg contains add_ace group.admin command allow, so an object named command.whatever is handed to everyone holding command. The raw variants pass principal and ace through exactly as given, with no prefixing and no principal normalisation, so qbcore.admin stays qbcore.admin instead of becoming group.qbcore.admin.

    They also solve something a script cannot solve on its own. FiveM checks add_ace against the resource that runs it, and import.lua compiles the modules into your resource, so an ExecuteCommand('add_ace ...') written in your script runs as resource.<your script> and gets denied. Called from your script, MSK.AddRawAce routes through msk_core's export, so the command runs as resource.msk_core and the single server.cfg line you already have covers every MSK script at once.

  • MSK.CanAddAce() returns whether msk_core is currently allowed to run add_ace. Lets a script check up front instead of firing commands that get refused and fill the console with Access denied for command add_ace.

Reminder: the server.cfg line
add_ace resource.msk_core command.add_ace allow
add_ace resource.msk_core command.remove_ace allow
add_ace resource.msk_core command.add_principal allow
add_ace resource.msk_core command.remove_principal allow

Changed files

fxmanifest.lua
modules/Ace/server.lua