12.08.2012, 03:08
Enjoy! I just got done making your command. (:
Код:
CMD:sellgun(playerid, params[]) { new otherid, weaponName; new string[64], PlayerName[24]; GetPlayerName(playerid, PlayerName, sizeof(PlayerName)); SendClientMessage(playerid, COLOR_WHITE, "--------------------------------[Guns You Can Sell]--------------------------------"); SendClientMessage(playerid, COLOR_WHITE, "Level 1: Bat(A-200) | Cane(A-200) | Flowers(A-50) | Katana(A-200) | SDPistol(A-250)"); SendClientMessage(playerid, COLOR_WHITE, "--------------------------------[Guns You Can Sell]--------------------------------"); else if(otherid == INVALID_PLAYER_ID) return SendClientMessage(playerid, CHAT_COLOR_RED, "SERVER: Uknown Player ID."); else { if(strcmp(params, "Bat", true, 3)) { GivePlayerWeapon(otherid, 5, 1); SendClientMessage(playerid, CHAT_COLOR_LIGHTBLUE, "Bat works."); } else if(strcmp(params, "Cane", true, 4)) { GivePlayerWeapon(otherid, 15, 1); SendClientMessage(playerid, CHAT_COLOR_LIGHTBLUE, "Cane works."); } else if(strcmp(params, "Flowers", true, 7)) { GivePlayerWeapon(otherid, 14, 1); SendClientMessage(playerid, CHAT_COLOR_LIGHTBLUE, "Flowers works."); } else if(strcmp(params, "Katana", true, 6)) { GivePlayerWeapon(otherid, 8, 1); SendClientMessage(playerid, CHAT_COLOR_LIGHTBLUE, "Katana works."); } else if(strcmp(params, "SDPistol", true, 8)) { GivePlayerWeapon(otherid, 23, 10000); SendClientMessage(playerid, CHAT_COLOR_LIGHTBLUE, "SDPistol works."); } } return 1; }