15.03.2010, 00:05
I've looked everywhere, I don't know how to fix it lol.
Please help me.
Please help me.
Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) { if(dialogid == CIVILIAN_DIALOG && response == 1) { TogglePlayerControllable(playerid, 1); if(listitem == 0) { SendClientMessage(playerid,0x1E90FFAA, "RAPIST: You can rape other players and infect them with STDs that could kill them"); GivePlayerWeapon(playerid,5,1); GivePlayerWeapon(playerid,22,100); GivePlayerWeapon(playerid,14,1); gTeam[playerid] = TEAM_RAPIST; CanChooseSkill[playerid] =0; } if(listitem == 1) { SendClientMessage(playerid,0x1E90FFAA, "Type /commands for your commands"); SendClientMessage(playerid,0x00FFFFAA, "GUN DEALER: If anyone needs weapons then you sell them some lead. Your prices are set by the game"); SendClientMessage(playerid,0x00FFFFAA, "You can also deliver guns to ammunations, just get in the PATRIOT car at ammunation stores in LS"); GivePlayerWeapon(playerid,29,500); GivePlayerWeapon(playerid,30,50); gTeam[playerid] = TEAM_GUNDEALER; CanChooseSkill[playerid] =0; } if(listitem == 2) { SendClientMessage(playerid,0x00FFFFAA, "DRUG DEALER: You will supply people with drugs for a price. Dont let people rip you off.."); SendClientMessage(playerid,0x00FFFFAA, "Keep a watch on the chat for players wanting drugs. Visit the drug house to replenish your stock"); GivePlayerWeapon(playerid,25,50); GivePlayerWeapon(playerid,28,100); GivePlayerWeapon(playerid,5,1); gTeam[playerid] = TEAM_DRGDEL; PlayerDrugs[playerid] = 500; SetPlayerToTeamColour(playerid); CanChooseSkill[playerid] =0; } if(listitem == 3) { SendClientMessage(playerid,0x00FFFFAA, "HITMAN: If anyone needs another player dead then they will contact you. Make sure you agree a price and get paid"); SendClientMessage(playerid,0x00FFFFAA, "Type /hits to see if there are any hit contracts available"); GivePlayerWeapon(playerid,27,250); GivePlayerWeapon(playerid,23,100); GivePlayerWeapon(playerid,31,250); gTeam[playerid] = TEAM_HITMAN; CanChooseSkill[playerid] =0; } if(listitem == 4) { SendClientMessage(playerid,0x00FFFFAA, "PRIVATE MEDIC: If anyone needs medical attention for cuts and bruses or STDs then you can cure then and heal them"); SendClientMessage(playerid,0x00FFFFAA, "You can also infect them with STDs that could kill them DO NOT HIT/INFECT THEM JUST TO HEAL/CURE THEM"); GivePlayerWeapon(playerid,22,250); gTeam[playerid] = TEAM_PVTMED; CanChooseSkill[playerid] =0; } if(listitem == 5) { SendClientMessage(playerid,0x00FFFFAA, "BOUNTY HUNTER: You have to help the cops take Escaped prisoners back into custody"); SendClientMessage(playerid,0x00FFFFAA, "Simply target RED players and type /ar (id) next to them to see if you have found an escaped convict"); SendClientMessage(playerid,0x00FFFFAA, "Type /bounty for details of Escaped Prisoners"); GivePlayerWeapon(playerid,27,250); GivePlayerWeapon(playerid,23,100); GivePlayerWeapon(playerid,31,250); gTeam[playerid] = TEAM_BOUNTY; CanChooseSkill[playerid] =0; } if(listitem == 6) { // Nothing more to copy-paste. } if(listitem == 7) { // Nothing more to copy-paste. } if(listitem == 8) { // Nothing more to copy-paste. } if(listitem == 9) { // Nothing more to copy-paste. } if(listitem == 10) { // Nothing more to copy-paste. } if(listitem == 11) { // Nothing more to copy-paste. } if(dialogid == STORE_DIALOG) { if(response) { if(listitem==0) { if(GetPlayerMoney(playerid) <= 1499) { { SendClientMessage(playerid, 0xA9A9A9AA, "|_24/7 Purchase Failed_|"); SendClientMessage(playerid, COLOR_ERROR, "You cannot afford to buy a Chainsaw ($1500)"); return 1; } GivePlayerMoney(playerid,-1500); SendClientMessage(playerid, 0xA9A9A9AA, "|_24/7 Purchase_|"); SendClientMessage(playerid, 0x00C7FFAA, "You have bought a Chainsaw. You were charged $1500"); GivePlayerWeapon(playerid,9,1); return 1; } if(listitem==1) { if(GetPlayerMoney(playerid) <= 4) { { SendClientMessage(playerid, 0xA9A9A9AA, "|_24/7 Purchase Failed_|"); SendClientMessage(playerid, COLOR_ERROR, "You cannot afford to buy flowers ($5)"); return 1; } GivePlayerMoney(playerid,-5); SendClientMessage(playerid, 0xA9A9A9AA, "|_24/7 Purchase_|"); SendClientMessage(playerid, 0x00C7FFAA, "You have bought flowers. You were charged $5"); GivePlayerWeapon(playerid,14,1); return 1; } if(listitem==2) { if(GetPlayerMoney(playerid) <= 99) { { SendClientMessage(playerid, 0xA9A9A9AA, "|_24/7 Purchase Failed_|"); SendClientMessage(playerid, COLOR_ERROR, "You cannot afford to buy a Baseball Bat ($100)"); return 1; } GivePlayerMoney(playerid,-100); SendClientMessage(playerid, 0xA9A9A9AA, "|_24/7 Purchase_|"); SendClientMessage(playerid, 0x00C7FFAA, "You have bought a Baseball Bat. You were charged $100"); GivePlayerWeapon(playerid,5,1); return 1; } if(listitem==3) { if(GetPlayerMoney(playerid) <= 19) { { SendClientMessage(playerid, 0xA9A9A9AA, "|_24/7 Purchase Failed_|"); SendClientMessage(playerid, COLOR_ERROR, "You cannot afford to buy Beer ($20)"); return 1; } GivePlayerMoney(playerid,-20); SendClientMessage(playerid, 0xA9A9A9AA, "|_24/7 Purchase_|"); SendClientMessage(playerid, 0x00C7FFAA, "You have bought Beer. You were charged $20"); new Float:beerhealth; GetPlayerHealth(playerid,beerhealth); if(beerhealth <=95) { SetPlayerHealth(playerid,beerhealth+5); return 1; } if(listitem==4) { if(GetPlayerMoney(playerid) <= 999) { { SendClientMessage(playerid, 0xA9A9A9AA, "|_24/7 Purchase Failed_|"); SendClientMessage(playerid, COLOR_ERROR, "You cannot afford to buy a Wallet ($1000)"); return 1; } } if(HasWallet[playerid] >= 1) { SendClientMessage(playerid, 0xA9A9A9AA, "|_24/7 Purchase Failed_|"); SendClientMessage(playerid, COLOR_ERROR, "You already have a Wallet"); return 1; } GivePlayerMoney(playerid,-1000); SendClientMessage(playerid, 0xA9A9A9AA, "|_24/7 Purchase_|"); SendClientMessage(playerid, 0x00C7FFAA, "You have bought a Wallet. You were charged $1000"); SendClientMessage(playerid, 0x00C7FFAA, "You can be robbed upto 3 times and not loose any cash"); HasWallet[playerid] =3; return 1; } if(listitem==5) { if(GetPlayerMoney(playerid) <= 499) { { SendClientMessage(playerid, 0xA9A9A9AA, "|_24/7 Purchase Failed_|"); SendClientMessage(playerid, COLOR_ERROR, "You cannot afford to buy a Parachute ($500)"); return 1; } GivePlayerMoney(playerid,-500); SendClientMessage(playerid, 0xA9A9A9AA, "|_24/7 Purchase_|"); SendClientMessage(playerid, 0x00C7FFAA, "You have bought a Parachute. You were charged $500"); GivePlayerWeapon(playerid,46,1); return 1; } } } return 1; }