RegisterCommand('ooc', function(source, args, rawCommand)
local playerName = GetPlayerName(source)
local msg = rawCommand:sub(5)
local name = getIdentity(source)
TriggerClientEvent('chat:addMessage', -1, {
template = '<div style="padding: 0.5vw; margin: 0.5vw; background-color: rgba(41, 41, 41, 0.6); border-radius: 3px;"><i class="fas fa-globe"></i> {0}:<br> {1}</div>',
args = { playerName, msg }
})
end, false)
BTW, the one i am using is a default ooc edit, is this the same?
Yeah, i just tried posting that one and it doesn’t work for default ooc. I wil need to type /ooc each time…
Do you found the solution ?
Has anyone found a solution to the problem i am having above?
Hello.
I have customized this but i need to fix a few bugs with it.
Could you help out??
I want to remove the default chat. “Mart475plz help me”. I want that to be removed.
I would like the ooc chat to be default.
And also, i would like to know how to fix the spaces between like the:
Anonymous Tweeted: omg
How do i fix that?
If anyone knows, or is trying to figure this out, we can together.
All help would be greatly appreciated.
UPDATE
I have sorta figured it out but still need to know how to make the.
OOC DEFAULT
REMOVING YELLOW TEXT WHILE TALKING OR TYPING UP A COMMAND.
OOC Default
esx_rpchat/server/main.lua
Change those lines (line27)
AddEventHandler('chatMessage', function(source, name, message)
if string.sub(message, 1, string.len("/")) ~= "/" then
local name = getIdentity(source)
TriggerClientEvent("sendProximityMessageMe", -1, source, name.firstname, message)
end
CancelEvent()
end)
To This
AddEventHandler('chatMessage', function(source, name, message)
if string.sub(message, 1, string.len("/")) ~= "/" then
local pName= getIdentity(source)
fal = pName.firstname .. " " .. pName.lastname
TriggerClientEvent('chat:addMessage', -1, {
template = '<div style="padding: 0.5vw; margin: 0.5vw; background-color: rgba(41, 41, 41, 0.6); border-radius: 3px;"><i class="fas fa-globe"></i> {0}:<br> {1}</div>',
args = { fal , message}
})
end
CancelEvent()
end)
AddEventHandler("chatMessage", function(source, args, raw)
CancelEvent()
end)
Dont forget to comment out or delete the basic ooc command
--[[
RegisterCommand('ooc', function(source, args, rawCommand)
local playerName = GetPlayerName(source)
local msg = rawCommand:sub(5)
local name = getIdentity(source)
TriggerClientEvent('chat:addMessage', -1, {
template = '<div style="padding: 0.5vw; margin: 0.5vw; background-color: rgba(41, 41, 41, 0.6); border-radius: 3px;"><i class="fas fa-globe"></i> {0}:<br> {1}</div>',
args = { playerName, msg }
})
end, false)
--]]
I dont know what you mean with your second question. please explain or show me what you want to remove.
It’s in the top image I posted, when you open chat and start typing than it is yellow, and when you hit enter than it’s yellow
If you changing basic chat to ooc than your message showing only in the box not in basic format. When you typing is different, you can find in your theme / style.css a following line (or similar) and you need to change the color line to modify the input color.

I’m not 100% sure is gonna be work but if you dont have definition to color try to include the following line in this input area
color: #b0bbbd;
If anyone know feel free to correct me.
can u help to fix the /me and /do command? not working for me.
not implemented, I using the following resource for /do /me
you rulz bro, thank you!
Nope i did not 
It removed the colon from my messages. Now whenever someone types their name and the message are linked together.
nvm fixed it 
what did you do to fix it? i need to fix mine too 





