How do I make a...
#1

I don't really know how to say that but I'll try:
How do I make something like square with text in the center of the screen when people are joining my server?
And how do I make the registration form?
Reply
#2

Код:
OnPlayerConnect(playerid)
{
new string[128],pName[24];
GetPlayerName(playerid, pName, 24 );
format(string,sizeof(string),"%s Joined The Server",pName);
GameTextForAll(string,5000,3);
return 1;
}
Reply
#3

Pretty sure he means Dialogs
Reply
#4

Quote:
Originally Posted by [AC
Etch ]
Код:
OnPlayerConnect(playerid)
{
new string[128],pName[24];
GetPlayerName(playerid, pName, 24 );
format(string,sizeof(string),"%s Joined The Server",pName);
GameTextForAll(string,5000,3);
return 1;
}
No, you didn't get me right. I want to make a box with text inside (Rules and stuff) and only played who joined can see it.
And also registration/login box
Reply
#5

a box with a text inside called textdraw,and if you want to create a login/registeration box u need to use dialog.
textdraw: https://sampwiki.blast.hk/wiki/TextDrawCreate
dialog: https://sampwiki.blast.hk/wiki/How_to_Create_a_Dialog
Reply
#6

under OnPlayerConnect :
Код:
ShowPlayerDialog(playerid, 9999, DIALOG_STYLE_MSGBOX, "Rules :", "rule\nrule\nrule\nrule\nrule", "Accept", "Decline");
// then /n mean a new line.

then Under OnDialogResponse add :
Код:
if(dialogid == 9999)
{
if(response == 0)
{
SendClientMessage(playerid, 0xAA3333AA, "You MUST Accept Those Rules Or Be Kicked!");
Kick(playerid);
new stringsys [256];
new pName4[MAX_PLAYER_NAME];
GetPlayerName(playerid, pName4, MAX_PLAYER_NAME);
format(stringsys, sizeof(stringsys), "[SYSTEM] %s Has Been Kicked For Not Accepting Rules!", pName4);
SendClientMessageToAll(0xAA3333AA, stringsys);
}
if(response == 1)
{
SendClientMessage(playerid, 0xAA3333AA, "Thank You For Accepting Our Rules.");
}
return 1;
}
that code will make if the player press Accept he can play , if he pressed Decline he gets kicked feel free to PM me any question
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)