Skip to content
Permalink
Browse files
Adding Condition to identify airport pickup (#787)
* Adding Condition to identify airport pickup

Solving #786 error from occuring.

* Update LegacyProcessing.pwn

* Update LegacyProcessing.pwn
  • Loading branch information
Specifer committed Jul 22, 2020
1 parent 384123f commit 5a8a3e6d56cfb3866c6da5a4d60b191d013d0798
Showing 1 changed file with 8 additions and 6 deletions.
@@ -142,13 +142,15 @@ LegacyOnPlayerPickUpPickup(playerid, pickupid)

// Airports:
// Quite simple how it works. When a player picks up the pickup, simply show the menu!
if(!g_PlayerMenu[playerid] && !IsPlayerInMinigame(playerid))
if(!g_PlayerMenu[playerid] && !IsPlayerInMinigame(playerid))
{
if(Time->currentTime() - AirTime[playerid] < 60)
{
SendClientMessage(playerid,Color::Red,"There are no flights departing right now! Try again later.");
return 1;
}
if (Time->currentTime() - AirTime[playerid] < 60) {
if (pickupid == g_AirportPickup[0] || pickupid == g_AirportPickup[1] ||
pickupid == g_AirportPickup[2] || pickupid == g_AirportPickup[3]) {
SendClientMessage(playerid,Color::Red,"There are no flights departing right now! Try again later.");
return 1;
}
}
g_PlayerMenu[ playerid ] = 1;

if (pickupid == g_AirportPickup[0])

0 comments on commit 5a8a3e6

Please sign in to comment.