Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR LUA

fivem commands example lua

Citizen.CreateThread(function() TriggerEvent('chat:addSuggestion', '/test', 'Testing this new command.') end)
RegisterCommand("test", function(source, args, rawCommandString)
    -- Colors can be found here: https://zap-hosting.com/guides/docs/en/fivem_servername_color/
    TriggerEvent('chatMessage', "^2TEST", { 255, 0, 62 }, "Testing this new command.")
end, false)

Source by docs.fivem.net #
 
PREVIOUS NEXT
Tagged: #fivem #commands #lua
ADD COMMENT
Topic
Name
9+7 =