• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Lua Help me with TALKTYPE White in chanels privates

Sarah Wesker

ƐƖєgαηт Sуηтαx ❤
Staff member
TFS Developer
Support Team
Joined
Mar 16, 2017
Messages
1,461
Solutions
163
Reaction score
2,184
Location
London
GitHub
MillhioreBT
YouTube
millhiorebt
Hi all, I need help with something that seems simple but I have not found anything simple, well it's about I want to send private messages in color white to the players.
it's not broadcast
 
Don't know what you really mean.

Do you want to change default Private Message color to white?
or
Do you need a command to send custom white messages(like "You advanced...") to a chosen player?

If it's a second case, you can try this:
LUA:
function onSay(player, words, param)
    if not player:getGroup():getAccess() then
        return true
    end
  
    if player:getAccountType() < ACCOUNT_TYPE_GOD then
        return true
    end  

    local split = param:split(",")
    if split[2] == nil then
        player:sendCancelMessage("No text has been inserted.")
        return false
    end

    local target = Player(split[1])
    if target == nil then
        player:sendCancelMessage("A player with that name is not online.")
        return false
    end
  
    Player(target):sendTextMessage(MESSAGE_EVENT_ADVANCE, tostring(split[2]))
    player:sendTextMessage(MESSAGE_STATUS_SMALL, string.format('MSG: "%s" sent to player %s.', split[2], target:getName()))
return false
end

On a first case, it's probably source edits.
 
Last edited:

Similar threads

Back
Top