Checkpoint timer
#1

hello. here is my work checkpoint timer:

pawn Код:
COMMAND:work(playerid, cmdtext)
{
    if (!IsPlayerInRangeOfPoint(playerid, 7.0, -64.1551,-1120.6709,1.0781))
    {
        return SendClientMessage(playerid, COLOR_RED, "You're not in range of the job");
    }
    else
    {
        SendClientMessage(playerid, blue, "Welcome to work!");
        SendClientMessage(playerid, yellow, "Please drive to the checkpoint to recieve your reward.");
        new thevehicle = CreateVehicle(498, -79.2382, -1128.1711, 1.0781, 0.0, 0, 0, 5000);
        PutPlayerInVehicle(playerid, thevehicle, 0);
        SetPlayerCheckpoint(playerid,1827.8311,-1075.7113,23.9317,3.0);
    }
    return 1;
}
how i make so "SetPlayerCheckpoint(playerid,1827.8311,-1075.7113,23.9317,3.0);" checkpoint can refresh every 2 seconds?
Reply
#2

Why do you need it to refresh every 2 seconds? That will just make your server lag.
Reply
#3

Quote:
Originally Posted by TheDiscussionCafe
Посмотреть сообщение
hello. here is my work checkpoint timer:

pawn Код:
code...
how i make so "SetPlayerCheckpoint(playerid,1827.8311,-1075.7113,23.9317,3.0);" checkpoint can refresh every 2 seconds?
Where are you setting the checkpoint?

Quote:
Originally Posted by iGetty
Посмотреть сообщение
Why do you need it to refresh every 2 seconds? That will just make your server lag.
It wont really lag from a two second interval.
Reply
#4

Why would you want to 'refresh' it? Just don't set another checkpoint for that player? If you're using Incognito's streamer use

pawn Код:
TogglePlayerAllDynamicCPs(playerid, false);
SetPlayerCheckpoint(...);
and only your set checkpoint will be set.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)