Agency Docs
QBESXStandalone

Agency-Chat Eksporty & API

Czat na Twój serwer FiveM w stylu Agency, o identycznym wyglądzie jak Agency Notify i Agency Progressbar.

v1.2.0Płatny5 Strony

01Eksporty klienta

EksportOpis
exports.chat:addMessage(message)Adds a message to the own chat, same table as chat:addMessage (args, color, template). Optional agency = { tag, tone } gives it the Agency tag look.
exports.chat:addSuggestion(name, help, params)Adds a command suggestion with help text and parameters, same as chat:addSuggestion.
exports.chat:isOpen()true while the chat input is open.

02Eksporty serwera

EksportOpis
exports.chat:addMessage(target, message)Sends a message to one player (-1 for everyone), same table as chat:addMessage.
exports.chat:registerMessageHook(function(source, outMessage, hookRef) end)Sees and changes every typed message before it goes out, like the default chat. hookRef.cancel() stops it.
exports.chat:registerMode({ name, displayName, color, seObject, cb })Adds a chat mode players switch to with Tab, like the default chat.

03Eventy

NazwaStronaOpis
chat:addMessageKlientDefault chat event, works unchanged. TriggerClientEvent('chat:addMessage', source, { args = { 'SYSTEM', 'Hello' } }).
chatMessageKlientOld default chat event (author, color, text), works unchanged.
chat:addSuggestionKlientDefault event for one command suggestion. chat:addSuggestions and chat:removeSuggestion work as well.
chat:addTemplateKlientDefault event for message templates, works unchanged.
chat:addMode / chat:removeModeKlientDefault events for chat modes, work unchanged.
chat:clearKlientClears the chat of this player.

Nadal nie idzie po tej stronie? Nasze wsparcie przejmuje sprawę.