- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
// Step 2
inline CreateCharacterDialogStep2(playerid, dialogid, response, listitem, string:inputtext[]) {
#pragma unused dialogid, listitem, inputtext
if(!response) return CreateCharacter(playerid);
if(strlen(inputtext) < MIN_PLAYER_CHARACTER_NAME || strlen(inputtext) > MAX_PLAYER_NAME) return CreateCharacter(playerid);
- if(!IsRolePlayNickname(inputtext)) return CreateCharacter(playerid);
- SetPVarString(playerid, "name", inputtext);
+ if(!IsRolePlayNickname(str_replace(" ", "_", inputtext))) return CreateCharacter(playerid);
+ SetPVarString(playerid, "name", str_replace(" ", "_", inputtext));
format(title, sizeof(title), "Character creating - Step 3: Sex");
format(content, sizeof(content), "\
Skip\r\n\%s\r\n\%s\
", Group_GetName(gMale), Group_GetName(gFemale));
Dialog_ShowCallback(playerid, using inline CreateCharacterDialogStep3, DIALOG_STYLE_LIST, title, content, "Next", "Back");
return false;
}