Adding color to chat messages?Solved

ive made a plugin for my server and it prints to chat " welcome to the server Sonnymack" How would i make it in colour? i don't know that much about code also.


namespace Oxide.Plugins
{
    [Info("welcome", "Sonnymack", "1.0")]
    [Description("A helpful comand that welcomes you to the Server")]
    public class welcome : RustPlugin
    {
        void Init()
        {
            Puts("Init!");
        }

        void OnPlayerConnected(BasePlayer player)
        {
            PrintToChat("Welcome to the server" + player.displayName);
            PrintToChat("We Hope you enjoy your stay");
        }
    }
}
PrintToChat("<color=#fff>We Hope you enjoy your stay<\color>");
Use slash instead of backslash
PrintToChat("<color=#fff>We Hope you enjoy your stay</color>");
thanks what about when it does in chat the "welcome to the server" line ive got it so it also displays the players name at the end but it doesent have a space its like "Welcome to the serversteamname" when i want it to do "Welcome to the server steamname"
Hey, check out other plug-ins' code. Find a plugin, read the .cs, and get ideas from all the mods' code on here.

Merged post

"Welcome to the server " + with a space after server, before the qoute.
You could also use a $ sign and it allows you to keep the string together, example is showing if you are passing a BasePlayer.

Example:
$"Welcome to the server, {player.displayName}"
Locked automatically