27.04.2018, 09:01
I have problem using OnPlayerPickUpDynamicPickup callback. I have dealership system using pickup as indicator to show the textdraw. Then i have entrance system using pickup too, but iam not using the callback for the pickup. The problem is on the entrance pickup, i can see the dealership detail textdraw when i am on entrance pickup, how can i fix this problem?
this is the code:
Image: see green marker
this is the code:
PHP код:
public OnPlayerPickUpDynamicPickup(playerid, pickupid)
{
for (new i; i != MAX_DEALER; i++) if(DealershipData[i][dExists] && (pickupid == DealershipData[i][dPickup]))
{
ShowPlayerFooter(playerid, sprintf("~n~~b~~h~%s~n~~g~~h~Stock: ~y~%d~n~~g~~h~Status: %s~n~~g~~h~type /buycar to buy", DealershipData[i][dName], DealershipData[i][dStock], (DealershipData[i][dLock] == 1) ? ("~r~~h~Close") : ("~g~~h~Open")), 1000);
}
return 1;
}
