Jump to content

outPutColoredMessage? DaFuq?


'LinKin

Recommended Posts

Posted

Hello,

I've seen some stuff like this

outputColoredMessage ( "|C_PLAY|TITLE |C_1|This is coloured somehow |C_2| Another Colour now." ) 

Just wondering, what's that..?

I've browsed on google, looking after some MTA:Wiki feedback. But found nothing...

Can someone tell me how it works? because I've tried to put one line like this in a script I made, but it doesn't output anything in the chatbox.

For example; where do you define the colors for:

|C_PLAY|

|C_1|

|C_2|

Thanks.

Need a clanwar script? Click here!

Do you want some free scripts for your DD server? Visit my website.

Posted

It's defined function - same as "getPlayerFromNamePart" in example below :

function getPlayerFromNamePart(name) 
    if name then  
        for i, player in ipairs(getElementsByType("player")) do 
            if string.find(getPlayerName(player):lower(), tostring(name):lower(), 1, true) then 
                return player  
            end 
        end 
    end 
    return false 
end 

u can use it later in next functions . Just u have to define what's "outputColoredMessage".

Posted

That function is not a native MTA function.

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

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...