radio help!
#1

Hello. ive made a ''senate'' radio wich i want all the criminal factions be able to see but the radio dosnt send out to any of the factions.. what have a done wrong?

pawn Код:
if(strcmp(cmd, "/Senate", true) == 0 || strcmp(cmd, "/sen", true) == 0)
    {
            if(PlayerInfo[playerid][pMara] == 0)
            {
                SendClientMessage(playerid, TEAM_CYAN_COLOR, "You are NOT part of the Senate!");
                return 1;
            }

            new length = strlen(cmdtext);
            while ((idx < length) && (cmdtext[idx] <= ' '))
            {
                idx++;
            }
            new offset = idx;
            new result[128];
            while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
            {
                result[idx - offset] = cmdtext[idx];
                idx++;
            }
            result[idx - offset] = EOS;
            if(!strlen(result))
            {
                SendClientMessage(playerid, COLOR_GRAD2, "USAGE: (/sen)ate [senate radio annouce]");
                return 1;
            }
            if(PlayerInfo[playerid][pMara] == 1)
            {
                if(PlayerInfo[playerid][pMara] == 1) { format(string, sizeof(string), "[Criminal Senate]:(radio): %s, over.", result);}
                else if(PlayerInfo[playerid][pMara] == 2) { format(string, sizeof(string), "[Criminal Senate]:Senior Senator (radio): %s, over.", result);}
                else if(PlayerInfo[playerid][pMara] == 3) { format(string, sizeof(string), "[Criminal Senate]:Lead Senator (radio): %s, over.", result);}
                else if(PlayerInfo[playerid][pMara] == 4) { format(string, sizeof(string), " [Unknown] [Criminal Senate] (radio): %s, over.", result);}
               
                ProxDetector(7.5, playerid, string,COLOR_CHAT1,COLOR_CHAT2,COLOR_CHAT3,COLOR_CHAT4,COLOR_CHAT5);
                SentMessage[playerid] = 1;
                SendRadioMessage(5 && 6 && 8 && 13 && 14 && 15 && 16 && 17 && 18, TEAM_RADIO_COLOR, string);
                SentMessage[playerid] = 1;
                new y, m, d;
                new h,mi,s;
                getdate(y,m,d);
                gettime(h,mi,d);
                format(string, sizeof(string), "[%d/%d/%d](%d:%d:%d) %s (radio): (%s)",d,m,y,h,mi,s, result);
                RadioChatLog(string);
                return 1;
            }
            return 1;
}
Reply
#2

a friend said that it was something wrong with this lines

pawn Код:
ProxDetector(7.5, playerid, string,COLOR_CHAT1,COLOR_CHAT2,COLOR_CHAT3,COLOR_CHAT4,COLOR_CHAT5);
                SentMessage[playerid] = 1;
                SendRadioMessage(5 && 6 && 8 && 13 && 14 && 15 && 16 && 17 && 18, TEAM_RADIO_COLOR, string);
                SentMessage[playerid] = 1;
                new y, m, d;
                new h,mi,s;
                getdate(y,m,d);
                gettime(h,mi,d);
                format(string, sizeof(string), "[%d/%d/%d](%d:%d:%d) %s (radio): (%s)",d,m,y,h,mi,s, result);
                RadioChatLog(string);
                return 1;
            }
            return 1;
}
but he wasnt sure.
Reply
#3

please help me, i realy need this!
Reply
#4

Error message?
Reply
#5

Quote:
Originally Posted by MrBorsh
Посмотреть сообщение
Error message?
no errors, it just dosent send out to any of the faction numbers 5, 6, 8, 13, 14, 15, 16, 17 or 18
Reply
#6

like if i type "/sen test" it dosent show on the other radios, it only shows for me that i said it but noone else see it
Reply
#7

anyone knows the problem?
Reply
#8

bump
Reply
#9

Can you show your SendRadioMessage function?
Reply
#10

Never seen this function before:
pawn Код:
SendRadioMessage(5 && 6 && 8 && 13 && 14 && 15 && 16 && 17 && 18, TEAM_RADIO_COLOR, string);
Mind showing the stock/public for this function?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)