View Single Post
bigdaddy424
Senior Member
Join Date: Oct 2021
Location: Jupiter
Old 03-17-2024 , 15:58   Re: autoresponder edit
Reply With Quote #5

something like this should work
PHP Code:
new mapname[32];
public 
plugin_init() get_mapname(mapname31);
stock setColor(string[], len)
{
    if (
contain(string"!t") != -|| contain(string"!g") != -|| contain(string,"!n") != -1)
    {
        
//Some nice shiny colors ^^
        
replace_all(stringlen"!t""^x03");
        
replace_all(stringlen"!n""^x01");
        
replace_all(stringlen"!g""^x04");
        
        
//Work away a stupid bug
        
format(stringlen"^x01%s"string);
    }

    if (
contain(string"%online%") != -1)
    {
        
replace_all(stringlen"%online%"fmt("%d"get_playersnum()));
    }

    if (
contain(string"%mapname%") != -1)
    {
        
replace_all(stringlen"%mapname%"mapname);
    }

__________________
bigdaddy424 is offline