28.11.2012, 09:21
pawn Код:
CMD:buy(playerid, params[])
{
new idx = GetPlayerVirtualWorld(playerid)-100;
if(idx > 0 && idx < MAX_BIZ && BizInfo[idx][bType] != 1 && BizInfo[idx][bType] != 2 && BizInfo[idx][bType] != 3 && BizInfo[idx][bType] != 4 && BizInfo[idx][bType] != 6 || idx < 1 || idx > MAX_BIZ) return SendClientMessage(playerid, COLOR_LIME, "You are not inside a business.");
if(IsAt247(playerid))
{
ShowPlayerDialog(playerid, STOREMENU, DIALOG_STYLE_LIST, "24/7", "Cell Phone $400\nPhone Book $4000\nDice $400\nCondom $40\nCD Player $40\nSpraycan $160\nRope $800\nCigar $40\nSprunk $8\nVehicle Lock $4000\nPortable Radio $40000\nCamera $160\nLottery Ticket $800\nCheckbook $400\nMask $5000\nBoombox $50000\nSuitCase $10000", "Buy", "Cancel");
}
else if(BizInfo[idx][bType] == 3)
{
ShowPlayerDialog(playerid, AMMUMENU, DIALOG_STYLE_LIST, "Ammunation Shop", "Shotgun (5000)\nMp5 (20000)\nDeagle (35000)\nM4 (75000)\nFullVest (3000)", "Buy", "Cancel");
}
return 1;
}