dcmd_zaladuj(playerid, params[])
{
#pragma unused params
new vehicleid = GetPlayerVehicleID(playerid);
new pid = GetVehicleModel(vehicleid);
if(gGracz[playerid][Towar] == 0)
{
if(pid == 482 || pid == 459 || pid == 455 || pid == 456 || pid == 440 || pid == 433 || pid == 414 || pid == 413)
{
for(new pz; pz < sizeof(PunktyZaladunku); pz++)
{
if(IsPlayerInRangeOfPoint(playerid, 10, PunktyZaladunku[pz][0],PunktyZaladunku[pz][1],PunktyZaladunku[pz][2]))
{
ShowPlayerDialog(playerid, D_TOWARY, DIALOG_STYLE_LIST, "Zaladunek", "MlekonPaliwonOlejenJogurty", "Zaladuj", "Anuluj");
}
}
SendClientMessage(playerid, COLOR_RED, "Nie jestes w punkcie zaladunkowym!");
}
else
{
SendClientMessage(playerid, COLOR_RED, "W tym pojezdzie nie mozesz przewozic towarow !");
}
}
return 1;
}