Jump to content

Namecolor Player !


//_Dragon

Recommended Posts

Hey , i want add namecolor player in this script like when player namecolor has color blue when he talk to chat his name blue will be showing with the color blue :/

function globalMessage(thePlayer, cmd, ...)

local message = table.concat ( { ... }, " " )

local name = getPlayerName(thePlayer)

outputChatBox("(Local) "..name..": #ffffff"..message, getRootElement(), 255, 255, 255, true)

end

addCommandHandler("Local", globalMessage)

Link to comment
  • Replies 69
  • Created
  • Last Reply

Top Posters In This Topic

thy this :wink:

function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local name = getPlayerName(thePlayer) 
local r, g, b = getTeamColor(thePlayer) 
outputChatBox("(Local) "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

Link to comment
thy this :wink:
function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local name = getPlayerName(thePlayer) 
local r, g, b = getTeamColor(thePlayer) 
outputChatBox("(Local) "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

Not working dude

help ?

Link to comment

Debugscript problem in GetPlayerNametagColor :/

http://imgur.com/WZ5fBPD

function globalMessage(thePlayer, cmd, ...) 
    local message = table.concat ( { ... }, " " ) 
    local name = getPlayerName(thePlayer) 
    local r,g,b = getPlayerNametagColor (player) 
    outputChatBox("(Local) "..name..": #ffffff"..message, getRootElement(), r, g, b, true ) 
    end 
addCommandHandler("Local", globalMessage) 

Edited by Guest
Link to comment

maybe that, and maybe definition "Source or thePlayer"

function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local name = getPlayerName(source) 
local r,g,b = getPlayerNametagColor ( source ) -- add 
outputChatBox("[Local] "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

Link to comment
maybe that, and maybe definition "Source or thePlayer"
function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local name = getPlayerName(source) 
local r,g,b = getPlayerNametagColor ( source ) -- add 
outputChatBox("[Local] "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

Bro ur code is not working mine is working Only i have problem in getPlayerNameTagcolor i hope some one fixe it

Link to comment
function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local name = getPlayerName(thePlayer) 
local r,g,b = getPlayerNametagColor ( thePlayer ) -- add 
outputChatBox("[Local] "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

try this maybe it can work

Link to comment
function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local name = getPlayerName(thePlayer) 
local r,g,b = getPlayerNametagColor ( thePlayer ) -- add 
outputChatBox("[Local] "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

try this maybe it can work

Work perfect thanks but i want add color in [local] like Ex : #FF0000[Local] "..name.." but when i do it nameplayer too has taked the color ( red #FF0000 )

Link to comment
function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local name = getPlayerName(thePlayer) 
local r,g,b = getPlayerNametagColor ( thePlayer ) -- add 
outputChatBox("[Local] "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

try this maybe it can work

Work perfect thanks but i want add color in [local] like Ex : #FF0000[Local] "..name.." but when i do it nameplayer too has taked the color ( red #FF0000 )

outputChatBox("[Local] "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 

check this out again maybe the wrong is there

Link to comment
function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local chat = "[Local]" 
local name = getPlayerName(thePlayer) 
local r,g,b = getPlayerNametagColor ( thePlayer ) -- add 
outputChatBox("#FF0000[Local] "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

try this one maybe it could work

Link to comment
function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local chat = "[Local]" 
local name = getPlayerName(thePlayer) 
local r,g,b = getPlayerNametagColor ( thePlayer ) -- add 
outputChatBox("#FF0000[Local] "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

try this one maybe it could work

tagplayername has changed to red too :/

Link to comment
function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local chat = "[Local]" 
local name = getPlayerName(thePlayer) 
local r,g,b = getPlayerNametagColor ( thePlayer ) -- add 
outputChatBox("#FF0000[Local] "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

try this one maybe it could work

tagplayername has changed to red too :/

function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local chat = "#FF0000[Local]" 
local name = getPlayerName(thePlayer) 
local r,g,b = getPlayerNametagColor ( thePlayer ) -- add 
outputChatBox("..chat.. "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

try now :D

i wont leave you till i solve it :D

Link to comment
Doesnt worke bro :/

Nametagcolor take same color's [local]

function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local chat = "#FF0000[Local]" 
local name = getPlayerName(thePlayer) 
local r,g,b = getPlayerNametagColor ( thePlayer ) -- add 
outputChatBox("..chat.. "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

Link to comment
function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local chat = "#FF0000[Local]" 
local name = getPlayerName(thePlayer) 
local r,g,b = getPlayerNametagColor ( thePlayer )  
outputChatBox(" "#FF0000[Local]" "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

debuscript 3 : Loading script failed: Local\server.lua:6: ')' expected near '#'

Problem with ")" i think :3 help ?

Link to comment
function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local chat = "#FF0000[Local]" 
local name = getPlayerName(thePlayer) 
local r,g,b = getPlayerNametagColor ( thePlayer )  
outputChatBox(" "#FF0000[Local]" "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

debuscript 3 : Loading script failed: Local\server.lua:6: ')' expected near '#'

Problem with ")" i think :3 help ?

try the new one i posted.

Link to comment
function globalMessage(thePlayer, cmd, ...) 
local message = table.concat ( { ... }, " " ) 
local chat = "#FF0000[Local]" 
local name = getPlayerName(thePlayer) 
local r,g,b = getPlayerNametagColor ( thePlayer ) -- add 
outputChatBox("..chat.. "..name..": #ffffff"..message, getRootElement(), r, g, b, true) 
end 
addCommandHandler("Local", globalMessage) 

Nah doesnt work

it show only nametag player

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...