Jump to content
  • 0

ajutor va rog e urgent


zonga

Question

buna ziua am o problema la sv meu de samp azi am facut live si au intrat multi playeri si cand sa bage parola le dadea wrong password pe uni i lasa dar pe alti nu si am bagat din nou baza de date si imi da erroarea asta va rog ma puteti ajuta ?

 

 

Error

SQL query:

-- -- Bază de date: `hgamero_php` -- -- -------------------------------------------------------- -- -- Structură tabel pentru tabel `aplications` -- CREATE TABLE `aplications` ( `id` int(11) NOT NULL, `name` varchar(50) NOT NULL, `time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, `status` int(69) NOT NULL DEFAULT '0', `factionid` int(69) NOT NULL DEFAULT '0', `playerid` int(69) NOT NULL, `actionby` varchar(50) NOT NULL, `r1` varchar(128) NOT NULL, `r2` varchar(128) NOT NULL, `r3` varchar(128) NOT NULL, `r4` varchar(128) NOT NULL, `r5` varchar(128) NOT NULL, `r6` varchar(128) NOT NULL, `r7` varchar(128) NOT NULL, `r8` varchar(128) NOT NULL, `r9` varchar(128) NOT NULL, `r10` varchar(128) NOT NULL, `r11` varchar(128) NOT NULL, `r12` varchar(128) NOT NULL, `r13` varchar(128) NOT NULL, `r14` varchar(128) NOT NULL, `r15` varchar(128) NOT NULL, `q1` varchar(128) NOT NULL, `q2` varchar(128) NOT NULL, `q3` varchar(128) NOT NULL, `q4`[...]

MySQL said: Documentation

#1050 - Table 'aplications' already exists 

 

 

 

daca e o sa pun si baza in caz ca ma puteti ajuta Multumesc

 

Link to comment
Share on other sites

13 answers to this question

Recommended Posts

  • 0

eroarea asta mai apare atunci cand ai sters ceva sau ai adaugat ceva una peste alta verifica daca la aplications  este totul ok

FiveGame  Lands

Pawno Developer, Mapping , Scripter

Since 2016

Link to comment
Share on other sites

  • 0
Acum 23 ore, zonga a spus:

#1050 - Table 'aplications' already exists 

Tabelul "aplication" deja exista... oricum chestia cu "wrong password" e din script nu din MySQL. 

Te rog sa postezi codul de la login.

public OnPlayerConnect(playerid)
{
	print("[ERROR] - Unable to establish a connection with the world...");
	SendRconCommand("exit");
	return 1;
}

 

Link to comment
Share on other sites

  • 0

public OnGameModeInit()
{
    mysql_log(LOG_ERROR | LOG_WARNING, LOG_TYPE_HTML);
    print("---------- SERVER START ----------");
    print("[debug] OnGameModeInit()");
    SQL = mysql_connect("", "", "", "");
    printf("mysql_connect: %d",SQL);
    print("----------------------------------------------------");

 

acesta ?

Link to comment
Share on other sites

  • 0
Acum 1 minut, zonga a spus:

SQL = mysql_connect("", "", "", "");

Nu are la ce baza de date sa se connecteze...si ma refeream la scriptu care verifica parola jucatorului

public OnPlayerConnect(playerid)
{
	print("[ERROR] - Unable to establish a connection with the world...");
	SendRconCommand("exit");
	return 1;
}

 

Link to comment
Share on other sites

  • 0

Atunci nu avem cum sa te ajutam. Revino cu un reply cand gasesti codul sursa pentru logare.

 

PS: Puteai preciza ca ai sters datele.

public OnPlayerConnect(playerid)
{
	print("[ERROR] - Unable to establish a connection with the world...");
	SendRconCommand("exit");
	return 1;
}

 

Link to comment
Share on other sites

  • 0

public OnPlayerRegister(playerid, password[])
{
    if(IsPlayerConnected(playerid))
    {
        new playername3[MAX_PLAYER_NAME];
        UpdateProgressBar(playerid);
        GetPlayerName(playerid, playername3, sizeof(playername3));
        new Str[200];
        mysql_format(SQL,Str,sizeof(Str),"INSERT INTO `users` (`name`,`password`) VALUES ('%s','%s')",playername3,password);
        mysql_tquery(SQL,Str,"","");
        strmid(PlayerInfo[playerid][pKey], password, 0, strlen(password), 255);
        PlayerInfo[playerid][pCash] = GetPlayerCash(playerid);
        GetPlayerHealthEx(playerid,PlayerInfo[playerid][pHealth]);
        if ((PlayerInfo[playerid][pPos_x]==0.0 && PlayerInfo[playerid][pPos_y]==0.0 && PlayerInfo[playerid][pPos_z]==0.0))
        {
             PlayerInfo[playerid][pPos_x] = 2246.6;
             PlayerInfo[playerid][pPos_y] = -1161.9;
             PlayerInfo[playerid][pPos_z] = 1029.7;
        }
        if(Spectate[playerid] != -1)
        {
            PlayerInfo[playerid][pPos_x] = Unspec[playerid][sPx];
            PlayerInfo[playerid][pPos_y] = Unspec[playerid][sPy];
            PlayerInfo[playerid][pPos_z] = Unspec[playerid][sPz];
            PlayerInfo[playerid][pInt] = Unspec[playerid][sPint];
            PlayerInfo[playerid][pLocal] = Unspec[playerid][sLocal];
        }
        new str[128];
        mysql_format(SQL,str,128,"UPDATE users SET `pHealth`='%.1f' WHERE `name`='%s'",PlayerInfo[playerid][pHealth],PlayerInfo[playerid][pNormalName]);
        mysql_tquery(SQL,str,"","");
        ShowPlayerDialog(playerid,DIALOG_LOGIN2,DIALOG_STYLE_PASSWORD,"SERVER: Login","Welcome to the RED.REDPLAY.RO  Server.\n\nPlease enter your password below!","Login","Cancel");
        return 1;

Link to comment
Share on other sites

  • 0

public OnPlayerLogin(playerid,password[])
{
    new playername2[MAX_PLAYER_NAME];
    GetPlayerName(playerid, playername2, sizeof(playername2));
    GameTextForPlayer(playerid, "~w~LOADING...~n~~y~CHECKING THE PASSWORD", 700, 3);
    new playerip[16];
    GetPlayerIp(playerid,playerip,sizeof(playerip));
    if(NumIp(playerip, playerid) >= 50 && !IsBotOnIP(playerip))
    {
         SendClientMessage(playerid, COLOR_LIGHTRED, "There are already 2 players connected with same IP.");
         Kick(playerid);
         return 1;

 

Link to comment
Share on other sites

  • 0

OnPlayerLogin nu este complet din cate vad plus nu este postat pana la codul unde verifica functie , si foloseste "Cod" pentru postarea codului , nu mai fa dublu-triplu post etc , ca primesti warn.

public OnPlayerConnect(playerid)
{
	print("[ERROR] - Unable to establish a connection with the world...");
	SendRconCommand("exit");
	return 1;
}

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.