Passt alles nun aber wenn ich connectem erscheint kein Textdraw:new PlayerText:RegisterT[MAX_PLAYERS];
new PlayerText:LoginT[MAX_PLAYERS];
public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid)
{
if(_:playertextid != INVALID_TEXT_DRAW)
{
if(playertextid == LoginT[playerid])
{
ShowPlayerDialog(playerid,DIALOG_LOGIN,DIALOG_STYLE_INPUT,"Login","Bitte gib dein Passwort ein:","Login","Abbrechen");
PlayerTextDrawHide(playerid,LoginT[playerid]);
}
else if(playertextid == RegisterT[playerid])
{
ShowPlayerDialog(playerid,DIALOG_REGISTER,DIALOG_STYLE_INPUT,"Register","Bitte Gib ein Passwort an:","Register","Exit");
PlayerTextDrawHide(playerid,RegisterT[playerid]);
}
/*CancelSelectTextDraw(playerid); //Schließt den TD (Abbrechen) CancelSelectTextDraw = zu deutsch SchließeAusgewähltenTextdraw
}
PlayerTextDrawHide(playerid,ConnectT2[playerid]);
PlayerTextDrawHide(playerid,ConnectT1[playerid]);
PlayerTextDrawHide(playerid,RegisterT[playerid]);
PlayerTextDrawHide(playerid,LoginT[playerid]);
CancelSelectTextDraw(playerid);
}*/
}
return 1;
}
public OnPlayerConnect(playerid)
{
RegisterT[playerid] = CreatePlayerTextDraw(playerid, 226.875000, 208.250000, "Beginne ein Neues Leben!");
PlayerTextDrawLetterSize(playerid, RegisterT[playerid], 0.449999, 1.600000);
PlayerTextDrawAlignment(playerid, RegisterT[playerid], 1);
PlayerTextDrawColor(playerid, RegisterT[playerid], 255);
PlayerTextDrawSetShadow(playerid, RegisterT[playerid], 0);
PlayerTextDrawSetOutline(playerid, RegisterT[playerid], 1);
PlayerTextDrawBackgroundColor(playerid, RegisterT[playerid], 51);
PlayerTextDrawFont(playerid, RegisterT[playerid], 1);
PlayerTextDrawSetSelectable(playerid, ConnectT2[playerid], true);
PlayerTextDrawSetProportional(playerid, RegisterT[playerid], 1);
LoginT[playerid] = CreatePlayerTextDraw(playerid, 226.875000, 208.250000, "Logge dich in dein Leben ein!");
PlayerTextDrawLetterSize(playerid, LoginT[playerid], 0.449999, 1.600000);
PlayerTextDrawAlignment(playerid, LoginT[playerid], 1);
PlayerTextDrawColor(playerid, LoginT[playerid], 255);
PlayerTextDrawSetShadow(playerid, LoginT[playerid], 0);
PlayerTextDrawSetOutline(playerid, LoginT[playerid], 1);
PlayerTextDrawBackgroundColor(playerid, LoginT[playerid], 51);
PlayerTextDrawFont(playerid, LoginT[playerid], 1);
PlayerTextDrawSetProportional(playerid, LoginT[playerid], 1);
PlayerTextDrawSetSelectable(playerid, ConnectT2[playerid], true);
if(mysql_CheckAccount(playerid) == 0)
{
PlayerTextDrawShow(playerid,ConnectT2[playerid]);
PlayerTextDrawShow(playerid,ConnectT1[playerid]);
PlayerTextDrawShow(playerid,RegisterT[playerid]);
//ShowPlayerDialog(playerid,DIALOG_REGISTER,DIALOG_STYLE_INPUT,"Register","Bitte Gib ein Passwort an:","Register","Exit");
}
else if(mysql_CheckAccount(playerid) == 1)
{
PlayerTextDrawShow(playerid,ConnectT2[playerid]);
PlayerTextDrawShow(playerid,ConnectT1[playerid]);
PlayerTextDrawShow(playerid,LoginT[playerid]);
//ShowPlayerDialog(playerid,DIALOG_LOGIN,DIALOG_STYLE_INPUT,"Login","Bitte gib dein Passwort ein:","Login","Abbrechen");
}
return 1;
}