Timer on command
#17

Sorry, but this is like the final thing and then I'm done. Can't say how grateful I would be if someone came with the solution. Here's the pieces of code:

pawn Код:
if (strcmp("/bayonet", cmdtext, true, 8) == 0)
    {
    if (timercrifle[playerid] == 0)
        {
          SendClientMessage(playerid, 0xFFFFFFFF, "You have successfully reloaded your bayonet");
          SendClientMessage(playerid, 0xAAAAAAAA, "(( You may only use the bayonet each every six seconds (takes 6sec to reload). ))");
      ResetPlayerWeapons(playerid);
            GivePlayerWeapon(playerid, 33, 1);
        timercrifle[playerid] = 1;
            SetTimer("Timer2", 6000, false);
    }
        return 1;
    }
pawn Код:
if (strcmp("/usecanon", cmdtext, true, 9) == 0)
    {
    if (timertest[playerid] == 0)
    {
        if (IsPlayerInRangeOfPoint(playerid, 2, -1367.7334,-2329.4153,43.6167) || IsPlayerInRangeOfPoint(playerid, 2,
            -1367.6199,-2325.1145,43.6338) || IsPlayerInRangeOfPoint(playerid, 2, -1367.5388,-2320.6838,43.6629) || IsPlayerInRangeOfPoint(playerid, 2, -1367.0610,-2311.0056,43.6313) || IsPlayerInRangeOfPoint(playerid, 2, -1366.9612,-2306.8826,43.5795) || IsPlayerInRangeOfPoint(playerid, 2, -1366.8689,-2302.5981,43.5999) || IsPlayerInRangeOfPoint(playerid, 2, -1360.4092,-2302.2817,43.7645) || IsPlayerInRangeOfPoint(playerid, 2, -1350.3254,-2302.6692,43.8080) ||
            IsPlayerInRangeOfPoint(playerid, 2, -1340.1608,-2303.2659,43.5959) || IsPlayerInRangeOfPoint(playerid, 2, -1335.8135,-2308.0623,43.5575) || IsPlayerInRangeOfPoint(playerid, 2, -1336.5748,-2318.2117,43.5575) || IsPlayerInRangeOfPoint(playerid, 2, -1336.9384,-2328.4756,43.5575) || IsPlayerInRangeOfPoint(playerid, 2, -1341.9918,-2333.4768,43.6067) || IsPlayerInRangeOfPoint(playerid, 2, -1362.5692,-2332.3665,43.5644))
        {
          SendClientMessage(playerid, 0xFFFFFFFF, "This canon is ready to use.");
          SendClientMessage(playerid, 0xAAAAAAAA, "(( Please, stand at a canon when you use this weapon. ))");
                GivePlayerWeapon(playerid, 35, 1);
          timertest[playerid] = 1;
                SetTimer("Timer1", 60000, false);
        }
        else
        {
          SendClientMessage(playerid, 0xFFFFFFFF, "You are not near a canon or you have just used a canon, please let it reload.");
          SendClientMessage(playerid, 0xAAAAAAAA, "(( It takes sixty seconds for a canon to reload. ))");
        }
    }
    return 1;
    }
Reply


Messages In This Thread
Timer on command - by Galcio - 24.02.2010, 10:24
Re: Timer on command - by aircombat - 24.02.2010, 10:36
Re: Timer on command - by GaGlets(R) - 24.02.2010, 10:44
Re: Timer on command - by Galcio - 24.02.2010, 11:00
Re: Timer on command - by Razvann - 24.02.2010, 11:02
Re: Timer on command - by Galcio - 24.02.2010, 11:06
Re: Timer on command - by VonLeeuwen - 24.02.2010, 11:07
Re: Timer on command - by MenaceX^ - 24.02.2010, 11:11
Re: Timer on command - by VonLeeuwen - 24.02.2010, 11:13
Re: Timer on command - by Galcio - 24.02.2010, 11:17
Re: Timer on command - by VonLeeuwen - 24.02.2010, 11:18
Re: Timer on command - by Gamer_Z - 24.02.2010, 11:43
Re: Timer on command - by GaGlets(R) - 24.02.2010, 11:46
Re: Timer on command - by Gamer_Z - 24.02.2010, 12:37
Re: Timer on command - by VonLeeuwen - 24.02.2010, 12:40
Re: Timer on command - by Galcio - 24.02.2010, 15:22
Re: Timer on command - by Galcio - 24.02.2010, 16:21
Re: Timer on command - by GaGlets(R) - 24.02.2010, 16:35
Re: Timer on command - by Galcio - 24.02.2010, 16:47
Re: Timer on command - by Joe Staff - 24.02.2010, 17:11
Re: Timer on command - by Galcio - 24.02.2010, 17:26
Re: Timer on command - by Gamer_Z - 25.02.2010, 05:42

Forum Jump:


Users browsing this thread: 2 Guest(s)