Change the following code in qb-core/client/drawtext.lua:
localfunctionhideText() exports['brutal_textui']:Close()endlocalfunctiondrawText(text,_) exports['brutal_textui']:Open(text, "blue")end-- local function changeText(text, position) -- Can't use-- if type(position) ~= "string" then position = "left" end-- SendNUIMessage({-- action = 'CHANGE_TEXT',-- data = {-- text = text,-- position = position-- }-- })-- endlocalfunctionkeyPressed() CreateThread(function() -- Can't use--[[ SendNUIMessage({ action = 'KEY_PRESSED', }) ]]--Wait(500) hideText()end)endRegisterNetEvent('qb-core:client:DrawText', function(text,position) drawText(text, position)end)-- RegisterNetEvent('qb-core:client:ChangeText', function(text, position) -- Can't use-- changeText(text, position)-- end)RegisterNetEvent('qb-core:client:HideText', function() hideText()end)-- RegisterNetEvent('qb-core:client:KeyPressed', function() -- Can't use-- keyPressed()-- end)exports('DrawText', drawText)--exports('ChangeText', changeText) -- Can't useexports('HideText', hideText)exports('KeyPressed', keyPressed) -- Can't use
ESX.TextUI to Brutal TextUI
Navigate to es_extended/client/functions.lua and edit the following functions:
functionESX.TextUI(message,type)iftype=='info' then type ="blue"elseiftype=='success' then type ="green"elseiftype=='error' then type ="red"else type ='gray'end exports['brutal_textui']:Open(message, type)endfunctionESX.HideUI() exports['brutal_textui']:Close()end