warning 225: unreachable code
#1

C:\Users\Raul\Desktop\SA-MP Server\gamemodes\Proov.pwn(23953) : warning 225: unreachable code
C:\Users\Raul\Desktop\SA-MP Server\gamemodes\Proov.pwn(43610) : warning 225: unreachable code


THERES ONE MISTAKE:



pawn Код:
for(new i = 0; i < sizeof(SBizzInfo); i++)
            {
                if (PlayerToPoint(3, playerid,SBizzInfo[i][sbEntranceX], SBizzInfo[i][sbEntranceY], SBizzInfo[i][sbEntranceZ]))
                {
                    if(PlayerInfo[playerid][pPbiskey] == i || GetPlayerMoney(playerid) >= SBizzInfo[i][sbEntranceCost])
                    {
                        if(PlayerInfo[playerid][pPbiskey] != i)
                        {
                            if(SBizzInfo[i][sbLocked] == 1)
                            {
                                GameTextForPlayer(playerid, "~r~Closed", 5000, 1);
                                return 1;
                            }
                            if(SBizzInfo[i][sbProducts] == 0)
                            {
                                GameTextForPlayer(playerid, "~r~Out Of Stock", 5000, 1);
                                return 1;
                            }
                            else

                              return 1;

                            SafeGivePlayerMoney(playerid,-SBizzInfo[i][sbEntranceCost]);
                            gSpentCash[playerid] = GetPlayerMoney(playerid);
                            SBizzInfo[i][sbProducts]--;
                            SBizzInfo[i][sbTill] += SBizzInfo[i][sbEntranceCost];
                            ExtortionSBiz(i, SBizzInfo[i][sbEntranceCost]);
                            new dood[MAX_PLAYER_NAME];
                            GetPlayerName(playerid, dood, sizeof(dood));
                            format(string, sizeof(string), "%s payed $%d to enter sbiz %d", dood, SBizzInfo[i][sbEntranceCost], i);
                            printf("%s", string);
                            PayLog(string);
                            OnPropUpdate();
                        }
                    }

HERES THE OTHER


pawn Код:
PlayerInfo[playerid][pSex] = 1;
                ClearChatbox(playerid, 8);
                SendClientMessage(playerid, COLOR_GREEN, "-----------------------------------------------------------------------");
                SendClientMessage(playerid, COLOR_GREY, "Ok, so you are a Male.");
                SendClientMessage(playerid, COLOR_WHITE, "2. What is your birthdate? (Use dd/mm/yyyy)");
                SendClientMessage(playerid, COLOR_GREEN, "-----------------------------------------------------------------------");
                ClearChatbox(playerid, 2);
                new maleskin;
                maleskin = random(sizeof(CivMalePeds));
                SetPlayerSkin(playerid, maleskin);
                PlayerInfo[playerid][pChar] = maleskin;
                RegistrationStep[playerid] = 2;
                return 0;
            }
            else if((strcmp("female", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("female")))
            {
                PlayerInfo[playerid][pSex] = 2;
                ClearChatbox(playerid, 8);
                SendClientMessage(playerid, COLOR_GREEN, "-----------------------------------------------------------------------");
                SendClientMessage(playerid, COLOR_GREY, "Ok, so you are a Female.");
                SendClientMessage(playerid, COLOR_WHITE, "2. What is your birthdate? (Use dd/mm/yyyy)");
                SendClientMessage(playerid, COLOR_GREEN, "-----------------------------------------------------------------------");
                ClearChatbox(playerid, 2);
                new femaleskin;
                femaleskin = random(sizeof(CivFemalePeds));
                SetPlayerSkin(playerid, femaleskin);
                SetPlayerSkin(playerid, femaleskin);
                PlayerInfo[playerid][pChar] = femaleskin;
                RegistrationStep[playerid] = 2;
                return 0;
Reply


Messages In This Thread
warning 225: unreachable code - by dafuq - 04.10.2012, 12:30
Re: warning 225: unreachable code - by dafuq - 04.10.2012, 12:33
Re: warning 225: unreachable code - by Roel - 04.10.2012, 12:36
Re: warning 225: unreachable code - by dafuq - 04.10.2012, 12:39
Re: warning 225: unreachable code - by Roel - 04.10.2012, 12:45

Forum Jump:


Users browsing this thread: 1 Guest(s)