12.05.2011, 21:22
Hello! I'have a problem with faction vehicles.
Faction id 1 members can drive all factions car,
and factions id higher than 1 can't drive their cars.
Pawno dont get error, and i dont see errors too. Please help!
Heres the code:
Sorry for bad english...
Faction id 1 members can drive all factions car,
and factions id higher than 1 can't drive their cars.
Pawno dont get error, and i dont see errors too. Please help!
Heres the code:
Sorry for bad english...
Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger) { if(vehicleid == POLICE_VEHICLE[0]||POLICE_VEHICLE[1]||POLICE_VEHICLE[2]||POLICE_VEHICLE[3]||POLICE_VEHICLE[4]||POLICE_VEHICLE[5]\ ||POLICE_VEHICLE[6]||POLICE_VEHICLE[7]||POLICE_VEHICLE[8]||POLICE_VEHICLE[9]||POLICE_VEHICLE[10]||POLICE_VEHICLE[11]) { if(PlayerInfo[playerid][szervezet] != 1) // Itt leellenцrzцd, hogy a jбtйkos tagja-e egy frakciуnak { ClearAnimations(playerid); } } else if(vehicleid == MEDIC_VEHICLE[0]||MEDIC_VEHICLE[1]||MEDIC_VEHICLE[2]||MEDIC_VEHICLE[3]) { if(PlayerInfo[playerid][szervezet] != 2) // Itt leellenцrzцd, hogy a jбtйkos tagja-e egy frakciуnak { ClearAnimations(playerid); } } else if(vehicleid == REPORTER_VEHICLE[0]||REPORTER_VEHICLE[1]||REPORTER_VEHICLE[2]||REPORTER_VEHICLE[3]||REPORTER_VEHICLE[4]) { if(PlayerInfo[playerid][szervezet] != 3) // Itt leellenцrzцd, hogy a jбtйkos tagja-e egy frakciуnak { ClearAnimations(playerid); } } else if(vehicleid == CIA_VEHICLE[0]||CIA_VEHICLE[1]||CIA_VEHICLE[2]||CIA_VEHICLE[3]||CIA_VEHICLE[4]||CIA_VEHICLE[5]||CIA_VEHICLE[6]) { if(PlayerInfo[playerid][szervezet] != 4) // Itt leellenцrzцd, hogy a jбtйkos tagja-e egy frakciуnak { ClearAnimations(playerid); } } else if(vehicleid == GS_VEHICLE[0]||GS_VEHICLE[1]||GS_VEHICLE[2]) { if(PlayerInfo[playerid][szervezet] != 5) // Itt leellenцrzцd, hogy a jбtйkos tagja-e egy frakciуnak { ClearAnimations(playerid); } } else if(vehicleid == MAFFIA_VEHICLE[0]||MAFFIA_VEHICLE[1]||MAFFIA_VEHICLE[2]||MAFFIA_VEHICLE[3]||MAFFIA_VEHICLE[4]||MAFFIA_VEHICLE[5]) { if(PlayerInfo[playerid][szervezet] != 6) // Itt leellenцrzцd, hogy a jбtйkos tagja-e egy frakciуnak { ClearAnimations(playerid); } } else if(vehicleid == GOV_VEHICLE[0]) { if(PlayerInfo[playerid][szervezet] != 7) // Itt leellenцrzцd, hogy a jбtйkos tagja-e egy frakciуnak { ClearAnimations(playerid); } } return 1; }