Robbery Countdown
#1

Well Hi,
I'm using the SFCRRPG gamemode. When robbing a store, It displays the countdown(seconds) in a dialog with some text, I need to change it as a text draw countdown. The counting should be like a textdraw. Nevermind if its on bottom/top/middle. If you didn't understand what I said, Just give a reply and I'll try explaining more briefly..

Hope someone would help me,
Thanks.
Reply
#2

pawn Код:
forward CountDown();
public CountDown()
{
    new str[32];
    if(CountDownTimes > 1)
    {
        CountDownTimes --;
        format(str, sizeof(str), "~b~Count Down: ~r~%d", CountDownTimes);
        GameTextForAll(str, 1000, 6);
        SetTimer("CountDown",1000,0);
        for(new i = 0; i < MAX_PLAYERS; i++)
        {
            PlayerPlaySound(i, 5201, 0.0, 0.0, 0.0);
        }
    }
    else if(CountDownTimes <= 1)
    {
        CountDownTimes = 0;
        format(str, sizeof(str), "~y~GO!");
        GameTextForAll(str, 1000, 6);
        for(new i = 0; i < MAX_PLAYERS; i++)
        {
            PlayerPlaySound(i, 1058, 0.0, 0.0, 0.0);
        }
    }
    return 1;
that is 6 countdowns i made try it and tell me
pawn Код:
if(strcmp(cmdtext, "/countdown", true) == 0)
    {
        if(PlayerInfo[playerid][pAdmin] < 1) return 0;
        if(CountDownTimes != 0) return SendErrorMessage(playerid,"A countdown in progress!");
        CountDownTimes = 6;
        SetTimer("CountDown",500,0);
        return 1;
    }
EDITh sorry i thought normal countdown not robbery countdown this is normal sorry.
Reply
#3

Nope..
Take a look at this..
pawn Код:
if(getCheckpointType(playerid) == CP_BincoMain)
    {
        if(zones[current_zone][zone_name] == zones[161][zone_name])
        {
            if(JHBincoRobbedRecently >= 1)
            {
                SendClientMessage(playerid,COLOR_ERROR,"The Juniper Hill Binco has been robbed recently.");
                return 1;
            }
            if(rrand <= 30)
            {
                SendClientMessage(playerid,COLOR_ERROR,"Juniper Hill Binco robbery failed.");
                JHBincoRobbedRecently =320;
                return 1;
            }
            JHBincoRobbedRecently =320;
            RobbingJHBinco[playerid] =25;
            IncreaseWantedLevel(playerid,4);
            IncreasePlayerScore(playerid,1);
        FROM HERE  format(string,sizeof(string),"Robbing Binco.\nFinish Robbery in: %d seconds.\nPolice are on the way.",RobbingJHBinco[playerid]);
            ShowPlayerDialog(playerid,DIALOG_BINCO,DIALOG_STYLE_MSGBOX,"{FF0000}Binco Robbery",string,"Ok","Cancel"); TO HERE

            format(string,sizeof(string),"[POLICE RADIO] Suspect %s(%d) has begun to rob the Juniper Hill Binco! Get To Binco and arrest the suspect.",PlayerName(playerid),playerid);
            SendClientMessageToAllCops(string);

            format(string,sizeof(string),"[ROBBERY] %s(%d) has begun a robbery at Binco ..",PlayerName(playerid),playerid);
            SendClientMessageToAll(COLOR_RED,string);

            format(string,sizeof(string),"4[ROBBERY] %s(%d) has begun a robbery at Binco ..",PlayerName(playerid),playerid);
            IRC_GroupSay(gGroupID,IRC_CHANNEL,string);
            return 1;
        }
        return 1;
    }
Its a code for robbing BINCO, JUNIPER HOLLOW.
I need to make that dialog thing as a textdraw.
Reply
#4

Bump!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)