Gender dialog
#1

pawn Код:
case DIALOG_AGE:
        {
            if(response)
            {
                PlayerInfo[playerid][pAge] = strval(inputtext);
                new string[64];
                format(string, sizeof(string),"[Server]: So you are %s years old.", inputtext);
                SendClientMessage(playerid, COLOR_ORANGE, string);
                ShowPlayerDialog(playerid,DIALOG_SEX,DIALOG_STYLE_INPUT,"Gender Selection","You are a male or a female?","Done","Leave");
            }
        }

Hi, I'd like to do the same thing with gender using DIALOG_STYLE_MSGBOX, how am i suposed to write in the .ini file by example male if they choose male or female if they choose female ?
Reply
#2

ShowPlayerDialog(playerid,DIALOG_SEX,DIALOG_STYLE_ MSGBOX,"Gender Selection","You are a male or a female?","Male","Female");

if(response) male
else female
Reply
#3

First of all you will need be a create a variable in the Player Enumeration so that you can store 1 or 0 there as Female and Male!

I can do it completely for you on teamviewer if you want. Let me know!
Reply
#4

I already know it it works for int like money etc if itll store 0 or 1 when a player will/stats itll show 1 or 0 and not male or female
Reply
#5

ShowPlayerDialog List one to the player. First option should be male and second should be female. When they select male. Under OnDialogResponse increment the PlayerInfo[playerid][pGender] = 0; and PlayerInfo[playerid][pGender] = 1; when they select a female. Under OnPlayerDisconnect you might be saving stats of the player. There add this new Pvar and its current value.

On Stats

You will need to create an array which will change string when its 0 or 1 and use it show player gender under ShowStats!
Reply
#6

Could you please do it here for me im not sure to understand and i cant teamviewer im not at home presently
Reply
#7

Quote:
Originally Posted by vernz
Посмотреть сообщение
Could you please do it here for me im not sure to understand and i cant teamviewer im not at home presently
Paste your game mode at www.pastebin.com and send me the link via Private Messages! Ill add this feature into it for you for free !

Have fun.
Reply
#8

Fine later on when ill be at home like tomorow thanks
Reply
#9

Quote:
Originally Posted by vernz
Посмотреть сообщение
Fine later on when ill be at home like tomorow thanks
Allright anytime mate. Just PM me the game mode and ill fix or add what you want. Peace!
Reply
#10

I suggest starting off with this

https://sampforum.blast.hk/showthread.php?tid=309653
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)