08.02.2010, 02:43
ok i added a system in my gamemode that player can only enter hydras and rustlers but problem is : when i put the code in the gamemode script , it blocks all players (it set to block players and allow admins) and if putted in admin script , it does nothing , here is the code :::
Код:
//============================================================================== public OnPlayerKeyStateChange(playerid, newkeys, oldkeys) { if(PlayerInfo[playerid][Level] < 1) { new vehicleid = GetPlayerVehicleID(playerid); new modelid = GetVehicleModel(vehicleid); if(newkeys == 2 || newkeys == 3) { if(modelid != 476 && modelid != 520) { RemovePlayerFromVehicle(playerid); SendClientMessage(playerid,0xFF9900AA, "This vehicle is not allowed!"); } } } return 1; }