25.07.2016, 10:11
Код:
CMD:knife(playerid, params[]) { if (IsAHitman(playerid)) { if(PlayerInfo[playerid][pKnife] == 1 && GetPlayerWeapon(playerid) == 4) { PlayerInfo[playerid][pKnifeHidden] = 1; RemovePlayerWeapon(playerid, 4); SendClientMessageEx(playerid, COLOR_YELLOW, "You have hidden your knife."); } if(PlayerInfo[playerid][pKnifeHidden] == 1 && !GetPlayerWeapon(playerid) == 4) { PlayerInfo[playerid][pKnifeHidden] = -1; GivePlayerValidWeapon(playerid, 4); SendClientMessageEx(playerid, COLOR_YELLOW, "You have pulled out your knife."); } } else { SendClientMessageEx(playerid, COLOR_GREY, "You are not a member of the hitman agency!"); } return 1; }
Код:
pKnife, pKnifeGet, pKnifeHidden,