Whats wrong with this code?
#1

Hey guy, today isnt my day xD. Been running into multiple mistakes in my code and well im not sure whats wrong with this code:

pawn Код:
if(!response)
          {
                if(PlayerInfo[playerid][pCitizen] == 0)
                {
                    ShowPlayerDialog(playerid,6,DIALOG_STYLE_INPUT,"Citizenship Information","How Old Are You?","Send","Cancel");
                }
                if(PlayerInfo[playerid][pCitizen] == 1) return SendClientMessage(playerid, COLOR_RED, "You Are Already A Citizen");

          }
It automatically says " You are already a citizen, even when you are not.
Reply
#2

pawn Код:
if(!response)
          {
                if(PlayerInfo[playerid][pCitizen] == 0)
                {
                    ShowPlayerDialog(playerid,6,DIALOG_STYLE_INPUT,"Citizenship Information","How Old Are You?","Send","Cancel");
                }
               else
                {
                if(PlayerInfo[playerid][pCitizen] == 1) return SendClientMessage(playerid, COLOR_RED, "You Are Already A Citizen");
               }
          }
Reply
#3

This is a better code!

pawn Код:
if(!response)
{
    if ( PlayerInfo[ playerid ][ pCitizen ] == 0 )ShowPlayerDialog ( playerid, 6, DIALOG_STYLE_INPUT, "Citizenship Information","How Old Are You?", "Send", "Cancel" );
    else SendClientMessage(playerid, COLOR_RED, "You Are Already A Citizen");
}
Try and concentrate whatever you do!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)