11.11.2009, 00:29
Ok now i get 26errors i think i did the { wrong but figure out
Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) { new sendername[MAX_PLAYER_NAME]; new string[128]; if(dialogid==1337) //This is our Dialog ID as shown in the command { switch(pPurchasingItem[playerid]) { case ITEM_NONE: //This is the Dialog with the purchasing list, remember we set pPurchasingItem[playerid] to ITEM_NONE? this is why { if(!strcmp(inputtext,"Cell Phone",true)) //It's like commands, if the player chose the line with 'Cell Phone', then this is ran { pPurchasingItem[playerid]=ITEM_CELL_PHONE; //Now we're setting pPurchasingItem[playerid] to ITEM_CELL_PHONE for obvious reasons! ShowPlayerDialog(playerid,1337,DIALOG_STYLE_MSGBOX,"Purchase?","Purchase the Cell Phone for $150?","Yes","Nevermind"); return 1; } case ITEM_CELL_PHONE: //The player is on the ITEM_CELL_PHONE Dialog now. { if(response) //if(Player Hits "Yes" Button) { //Check to see if player has enough money ($150) if(GetPlayerMoney(playerid)<150)return SendClientMessage(playerid,COLOR_GRAD2,"You do not have enough money!"); //THIS CODE IS TAKEN DIRECTLY FROM THE ORIGINAL COMMAND, IT SHOULD BE EASY ENOUGH FOR YOU TO CREATE THE REST!! if(PlayerInfo[playerid][pTraderPerk] > 0) { new skill = 150 / 100; new price = (skill)*(PlayerInfo[playerid][pTraderPerk]); new payout = 150 - price; format(string, sizeof(string), "~r~-$%d", payout); GameTextForPlayer(playerid, string, 5000, 1); SafeGivePlayerMoney(playerid,- payout); SBizzInfo[9][sbTill] += payout; ExtortionSBiz(9, payout); } else { format(string, sizeof(string), "~r~-$%d", 150); GameTextForPlayer(playerid, string, 5000, 1); SafeGivePlayerMoney(playerid,-150); SBizzInfo[9][sbTill] += 150; ExtortionSBiz(9, 150); } PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0); new randphone = 100000 + random(899999);//minimum 1000 max 9999 PlayerInfo[playerid][pPnumber] = randphone; format(string, sizeof(string), " Mobile Phone Purchased your new Number is %d", randphone); SendClientMessage(playerid, COLOR_GRAD4, string); SendClientMessage(playerid, COLOR_GRAD5, "You can check this anytime by Typing /stats"); SendClientMessage(playerid, COLOR_WHITE, "HINT: You can now type /help to see your cell phone commands."); }else{ //Else Player Hits "NeverMind" Button SendClientMessage(playerid,COLOR_GRAD2,"Purchase canceled."); return 1; } } if(!strcmp(inputtext,"Scratch Card",true)) //Scratch Card { ShowPlayerDialog(playerid,1337,DIALOG_STYLE_MSGBOX,"Purchase?","","Yes","Nevermind"); //Finish the rest yourself pPurchasingItem[playerid]=ITEM_SCRATCH_CARD; return 1; } } if(!strcmp(inputtext,"Phone Book",true)) //Scratch Card { ShowPlayerDialog(playerid,1337,DIALOG_STYLE_MSGBOX,"Purchase?","","Yes","Nevermind"); //Finish the rest yourself pPurchasingItem[playerid]=ITEM_PHONE_BOOK; return 1; } { case ITEM_PHONE_BOOK: //The player is on the ITEM_CELL_PHONE Dialog now. { if(response) //if(Player Hits "Yes" Button) { //Check to see if player has enough money ($10) if(GetPlayerMoney(playerid)<150)return SendClientMessage(playerid,COLOR_GRAD2,"You do not have enough money!"); //THIS CODE IS TAKEN DIRECTLY FROM THE ORIGINAL COMMAND, IT SHOULD BE EASY ENOUGH FOR YOU TO CREATE THE REST!! if(PlayerInfo[playerid][pTraderPerk] > 0) { new skill = 10 / 100; new price = (skill)*(PlayerInfo[playerid][pTraderPerk]); new payout = 10 - price; SafeGivePlayerMoney(playerid,- payout); SBizzInfo[9][sbTill] += payout; ExtortionSBiz(9, payout); GameTextForPlayer(playerid, "~r~-$10", 5000, 1); } else { SafeGivePlayerMoney(playerid,- 10); SBizzInfo[9][sbTill] += 10; ExtortionSBiz(9, 10); format(string, sizeof(string), "~r~-$%d", 100); GameTextForPlayer(playerid, string, 5000, 1); } PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0); PlayerInfo[playerid][pPhoneBook] = 1; format(string, sizeof(string), " Phone Book Purchased you can look up any Players Number !"); SendClientMessage(playerid, COLOR_GRAD4, string); SendClientMessage(playerid, COLOR_WHITE, "HINT: Type /number <id/name>."); }else{ //Else Player Hits "NeverMind" Button SendClientMessage(playerid,COLOR_GRAD2,"Purchase canceled."); return 1; } } case ITEM_Dice: //The player is on the ITEM_CELL_PHONE Dialog now. { if(response) //if(Player Hits "Yes" Button) { //Check to see if player has enough money ($2) if(GetPlayerMoney(playerid)<150)return SendClientMessage(playerid,COLOR_GRAD2,"You do not have enough money!"); //THIS CODE IS TAKEN DIRECTLY FROM THE ORIGINAL COMMAND, IT SHOULD BE EASY ENOUGH FOR YOU TO CREATE THE REST!! if(PlayerInfo[playerid][pTraderPerk] > 0) { new skill = 10 / 100; new price = (skill)*(PlayerInfo[playerid][pTraderPerk]); new payout = 10 - price; SafeGivePlayerMoney(playerid,- payout); SBizzInfo[9][sbTill] += payout; ExtortionSBiz(9, payout); format(string, sizeof(string), "~r~-$%d", payout); GameTextForPlayer(playerid, string, 5000, 1); } else { SafeGivePlayerMoney(playerid,-10); SBizzInfo[9][sbTill] += 10; ExtortionSBiz(9, 10); format(string, sizeof(string), "~r~-$%d", 1); GameTextForPlayer(playerid, string, 5000, 1); } PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0); gDice[playerid] = 1; format(string, sizeof(string), " Dice Purchased you can throw your Dice."); SendClientMessage(playerid, COLOR_GRAD4, string); SendClientMessage(playerid, COLOR_WHITE, "HINT: Type /dice "); }else{ //Else Player Hits "NeverMind" Button SendClientMessage(playerid,COLOR_GRAD2,"Purchase canceled."); } return 1; }
Код:
C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2251) : error 004: function "SafeGivePlayerMoney" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2280) : error 004: function "SafeGivePlayerMoney" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2316) : error 004: function "SafeResetPlayerWeapons" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2317) : error 004: function "SafeGivePlayerWeapon" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2344) : error 004: function "SafeResetPlayerWeapons" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2631) : warning 235: public function lacks forward declaration (symbol "StopAnim") C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2671) : warning 235: public function lacks forward declaration (symbol "hospital") C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2678) : error 004: function "SafeGivePlayerMoney" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2718) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2729) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2741) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2745) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2757) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2761) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2765) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2769) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2773) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2777) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2781) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2785) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2797) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2801) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2805) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2809) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2813) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2825) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2829) : error 004: function "PlayerToPoint" is not implemented C:\DOCUME~1\Lilc\MYDOCU~1\HRP\GAMEMO~1\hrp32.pwn(2833) : error 004: function "PlayerToPoint" is not implemented Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 26 Errors.