Hali!
Segitséget kérnék ebbe a bejelentkezõs... dologba.
Az lenne a baj.. hogy amikor a pro**szeromon futtatom akkor nem akar bejelentkezni nekem:(
Mit Kellene beleirnom?:S
// includok
#include <a_samp>
#include <ZCMD>
#include <sscanf2>
#include <dini>
#include <dudb>
#include <dutils>
#define KÉK 0x0000FFAA
#define ZÖLD 0x33AA33AA
#define SÁRGA 0xFFFF00AA
#define COLOR_WHITE 0xFFFFFFAA
#define COLOR_PURPLE 0x9900FFAA
#define COLOR_BROWN 0x993300AA
#define NARANCS 0xFF9933AA
#define COLOR_CYAN 0x99FFFFAA
#define LILA 0xFF66FFAA
#define COLOR_LIME 0x99FF00AA
#define COLOR_BLACK 0x000000AA
#define COLOR_TURQ 0x00A3C0AA
#define COLOR_LIGHTBLUE 0x00BFFFAA
#define COLOR_GREENISHGOLD 0xCCFFDD56
#define COLOR_LIGHTCYAN 0xAAFFCC33
#define COLOR_LEMON 0xDDDD2357
#define COLOR_AQUA 0x7CFC00AA
#define COLOR_WHITEYELLOW 0xFFE87DAA
#define COLOR_BLUEAQUA 0x7E60FFAA
#define COLOR_GREENYELLOWWHITE 0xCBFF45AA
#define COLOR_DARKBLUE 0x15005EAA
#define COLOR_RED 0xAA3333AA
#define COLOR_ULTRARED 0xFF0606FF
#define COLOR_WARNING 0xFB0000FF
#define COLOR_VIOLET 0x8F698FFF
#define regisztracio 0
#define bejelentkezes 1
new pName[MAX_PLAYER_NAME];
new Belepve[MAX_PLAYERS];
enum JatekosInfo
{
pAdmin,
pPenz,
}
new JatekosAdatok[MAX_PLAYERS] [JatekosInfo];
main()
{
print(\"\\n----------------------------------\");
print(\" Blank Gamemode by your name here\");
print(\"----------------------------------\\n\");
}
public OnGameModeInit()
{
// Don\'t use these lines if it\'s a filterscript
SetGameModeText(\"Blank Script\");
AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
return 1;
}
public OnGameModeExit()
{
return 1;
}
public OnPlayerRequestClass(playerid, classid)
{
SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
new file[256];
new string[100];
GetPlayerName(playerid,pName,sizeof(pName));
format(file,sizeof(file),\"/karakterek/%s.ini\",pName);
if (!fexist(file))
{
format(string,sizeof(string),\"Üdv %s!Kérlek regisztrálj be ahoz hogy játszhass!\",pName);
ShowPlayerDialog(playerid,regisztracio,DIALOG_STYLE_INPUT,\"Regisztráció\",string,\"Regisztráció\",\"Kilép\");
}
if (fexist(file))
{
format(string,sizeof(string),\"Üdv %s!Kérlek lépj be!\",pName);
ShowPlayerDialog(playerid,bejelentkezes,DIALOG_STYLE_INPUT,\"Bejelentkezés\",string,\"Bejelentkezés\",\"Kilép\");
}
return 1;
}
public OnPlayerConnect(playerid)
{
return 1;
}
public OnPlayerDisconnect(playerid, reason)
{
return 1;
}
public OnPlayerSpawn(playerid)
{
return 1;
}
public OnPlayerDeath(playerid, killerid, reason)
{
return 1;
}
public OnVehicleSpawn(vehicleid)
{
return 1;
}
public OnVehicleDeath(vehicleid, killerid)
{
return 1;
}
public OnPlayerText(playerid, text[])
{
return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp(\"/mycommand\", cmdtext, true, 10) == 0)
{
// Do something here
return 1;
}
return 0;
}
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
return 1;
}
public OnPlayerExitVehicle(playerid, vehicleid)
{
return 1;
}
public OnPlayerStateChange(playerid, newstate, oldstate)
{
return 1;
}
public OnPlayerEnterCheckpoint(playerid)
{
return 1;
}
public OnPlayerLeaveCheckpoint(playerid)
{
return 1;
}
public OnPlayerEnterRaceCheckpoint(playerid)
{
return 1;
}
public OnPlayerLeaveRaceCheckpoint(playerid)
{
return 1;
}
public OnRconCommand(cmd[])
{
return 1;
}
public OnPlayerRequestSpawn(playerid)
{
return 1;
}
public OnObjectMoved(objectid)
{
return 1;
}
public OnPlayerObjectMoved(playerid, objectid)
{
return 1;
}
public OnPlayerPickUpPickup(playerid, pickupid)
{
return 1;
}
public OnVehicleMod(playerid, vehicleid, componentid)
{
return 1;
}
public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
{
return 1;
}
public OnVehicleRespray(playerid, vehicleid, color1, color2)
{
return 1;
}
public OnPlayerSelectedMenuRow(playerid, row)
{
return 1;
}
public OnPlayerExitedMenu(playerid)
{
return 1;
}
public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
{
return 1;
}
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
return 1;
}
public OnRconLoginAttempt(ip[], password[], success)
{
return 1;
}
public OnPlayerUpdate(playerid)
{
return 1;
}
public OnPlayerStreamIn(playerid, forplayerid)
{
return 1;
}
public OnPlayerStreamOut(playerid, forplayerid)
{
return 1;
}
public OnVehicleStreamIn(vehicleid, forplayerid)
{
return 1;
}
public OnVehicleStreamOut(vehicleid, forplayerid)
{
return 1;
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
if (dialogid == regisztracio)
{
if (response)
{
new file[100];
new string[100];
GetPlayerName(playerid,pName,sizeof(pName));
if (strlen(inputtext) == 0)
{
format(string,sizeof(string),\"Üdv %s!Kérlek regisztrálj be ahoz hogy játszhass!\",pName);
ShowPlayerDialog(playerid,regisztracio,DIALOG_STYLE_INPUT,\"Regisztráció\",string,\"Regisztráció\",\"Kilép\");
}
format(file,sizeof(file),\"/karakterek/%s.ini\",pName);
if(fexist(file))
{
dini_Create(file);
dini_IntSet(file,\"Antibug\",0);
dini_IntSet(file,\"Jelszó\",udb_hash(inputtext));
dini_IntSet(file,\"Penz\",0);
}
}
}
if (dialogid == bejelentkezes)
{
if (response)
{
new file[100];
new string[100];
GetPlayerName(playerid,pName,sizeof(pName));
if (strlen(inputtext) == 0)
{
format(string,sizeof(string),\"Üdv %s!Kérlek lépj be!\",pName);
ShowPlayerDialog(playerid,bejelentkezes,DIALOG_STYLE_INPUT,\"Bejelentkezés\",string,\"Bejelentkezés\",\"Kilép\");
return 0;
}
format(file,sizeof(file),\"/karakterek/%s.ini\",pName);
if(fexist(file))
{
new Jelszo=dini_Int(file, \"Jelszó\");
if (udb_hash(inputtext) == Jelszo)
{
Belepve[playerid]=1;
SendClientMessage(playerid,KÉK,\"sikeresen bejelentkeztél\");
}
else
{
SendClientMessage(playerid,KÉK,\"Rosz Jelszó ezért Kickelünk bisztonsági okokbol\");
Kick(playerid);
}
}
}
}
return 1;
}
public OnPlayerClickPlayer(playerid, clickedplayerid, source)
{
return 1;
}
Dupla hozzászólás automatikusan összefûzve. ( 2014. július 18. - 12:25:23 )
vki segitene mi lehet a baj?