CMD:setleader(playerid, params[]){new targetid,leader;if (sscanf(params, \"ud\", targetid,leader)) SendClientMessage(playerid, -1, \"[TIPP]: /setleader <playerid> <frakció>\");if (targetid == INVALID_PLAYER_ID) SendClientMessage(playerid, COLOR_ERROR,\"[HIBA]: Nincs ilyen játékos!\");else{ pInfo[targetid][LeaderJob] = leader; pInfo[targetid][LeaderRank] = 5;}return 1;}
if(dialogid == DIALOG_LOGIN) { if(response) // If they clicked \'Cancel\' or pressed esc { new string[24+4]; format(string,sizeof(string),\"users/%s.ini\",pName(playerid)); dfile_Open(string); if(!strcmp(inputtext, dfile_ReadString(\"Password\"))) { pInfo[playerid] = dfile_ReadInt(\"Admin\"); pInfo[playerid][Logins] = dfile_ReadInt(\"Logins\"); pInfo[playerid][Warns] = dfile_ReadInt(\"Warns\"); pInfo[playerid][PosX] = dfile_ReadFloat(\"PosX\"); pInfo[playerid][PosY] = dfile_ReadFloat(\"PosY\"); pInfo[playerid][PosZ] = dfile_ReadFloat(\"PosZ\"); pInfo[playerid][Money] = dfile_ReadInt(\"Money\"); pInfo[playerid][Kills] = dfile_ReadInt(\"Kills\"); pInfo[playerid][Deaths] = dfile_ReadInt(\"Deaths\"); pInfo[playerid][interior] = dfile_ReadInt(\"Interior\"); pInfo[playerid][skin] = dfile_ReadInt(\"Skin\"); pInfo[playerid][sex] = dfile_ReadInt(\"Sex\"); pInfo[playerid][Age] = dfile_ReadInt(\"Age\"); pInfo[playerid][Money] = dfile_ReadInt(\"Money\"); pInfo[playerid][Kills] = dfile_ReadInt(\"Kills\"); pInfo[playerid][Deaths] = dfile_ReadInt(\"Deaths\"); pInfo[playerid][Wanted] = dfile_ReadInt(\"Wanted\"); pInfo[playerid][Job] = dfile_ReadInt(\"Job\"); pInfo[playerid][LeaderJob] = dfile_ReadInt(\"LeaderJob\"); pInfo[playerid][LeaderRank] = dfile_ReadInt(\"LeaderRank\"); pInfo[playerid][Family] = dfile_ReadInt(\"Family\"); pInfo[playerid][FamilyRank] = dfile_ReadInt(\"FamilyRank\"); pInfo[playerid][CarJacks] = dfile_ReadInt(\"CarJacks\"); pInfo[playerid][JailTime] = dfile_ReadInt(\"JailTime\"); pInfo[playerid][AdminJailTime] = dfile_ReadInt(\"AdminJailTime\"); pInfo[playerid][Joint] = dfile_ReadInt(\"Joint\"); pInfo[playerid][Marihuana] = dfile_ReadInt(\"Marihuana\"); pInfo[playerid][MarihuanaLeaves] = dfile_ReadInt(\"MarihuanaLeaves\"); pInfo[playerid][Cocaine] = dfile_ReadInt(\"Cocaine\"); pInfo[playerid][beer] = dfile_ReadInt(\"Beer\"); pInfo[playerid][Water] = dfile_ReadInt(\"Water\"); pInfo[playerid][sandwich] = dfile_ReadInt(\"Sandwich\"); pInfo[playerid][bagett] = dfile_ReadInt(\"Bagett\"); pInfo[playerid][Crips] = dfile_ReadInt(\"Crips\"); pInfo[playerid][Cigarettes] = dfile_ReadInt(\"Cigarettes\"); pInfo[playerid][Paper] = dfile_ReadInt(\"Paper\"); pInfo[playerid][Lighter] = dfile_ReadInt(\"Lighter\"); pInfo[playerid][bandage] = dfile_ReadInt(\"Bandage\"); pInfo[playerid][Pills] = dfile_ReadInt(\"Pills\"); pInfo[playerid][Lighter] = dfile_ReadInt(\"Lighter\"); pInfo[playerid][bandage] = dfile_ReadInt(\"Bandage\"); pInfo[playerid][JapaneseSkill] = dfile_ReadInt(\"JapaneseSkill\"); pInfo[playerid][RussianSkill] = dfile_ReadInt(\"RussianSkill\"); pInfo[playerid][spanishSkill] = dfile_ReadInt(\"SpanishSkill\"); GivePlayerMoney(playerid,pInfo[playerid][Money]); LoggedIn[playerid] = true; CarJackTime[playerid] = 5*60; pInfo[playerid][Logins] ++; SpawnPlayer(playerid); printf(\"%s bejelentkezett!\",pName(playerid)); if(pInfo[playerid] == 1) SendClientMessage(playerid,-1,\"Üdvözöllek, admin segéd!\"); if(pInfo[playerid] == 2) SendClientMessage(playerid,-1,\"Üdvözöllek, admin!\"); if(pInfo[playerid] == 3) SendClientMessage(playerid,-1,\"Üdvözöllek, főadmin!\"); if(pInfo[playerid] == 4) SendClientMessage(playerid,-1,\"Üdvözöllek, fejlesztő!\"); if(pInfo[playerid] == 5) SendClientMessage(playerid,-1,\"Üdvözöllek, tulajdonos!\"); } else ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_PASSWORD, \"Bejelentkezés\", \"Az általad megadott jelszó hibás!\\nGépeld be a jelszavad!\", \"Belép\", \"Kilép\"); } else // Pressed ENTER or clicked \'Login\' button { Kick(playerid); } return 1; // We handled a dialog, so return 1. Just like OnPlayerCommandText. }
public OnPlayerSpawn(playerid){if(!IsPlayerNPC(playerid)){ Tempomat[playerid] = 0; printf(\"%s spawnolt!\",pName(playerid));if (LoggedIn[playerid] == false){ SetPlayerPos(playerid, 1461.0857,-894.0391,55.0890); SetPlayerCameraPos(playerid, 1480.6654,-861.4821,58.1107); SetPlayerCameraLookAt(playerid, 1417.5055,-800.6302,81.1883); Freeze(playerid);}else if (LoggedIn[playerid] == true){ if(WeatherID == 1) SetWeather(1); else if(WeatherID == 2) SetWeather(3); else if(WeatherID == 3) SetWeather(4); else if(WeatherID == 4) SetWeather(; else if(WeatherID == 5) SetWeather(4); else if(WeatherID == 6) SetWeather(9); SetCameraBehindPlayer(playerid); if(pInfo[playerid][Logins] >= 1) { SetPlayerPos(playerid,pInfo[playerid][PosX],pInfo[playerid][PosY],pInfo[playerid][PosZ]); SetPlayerInterior(playerid,pInfo[playerid][interior]); SetPlayerSkin(playerid,pInfo[playerid][skin]); ResetPlayerWeapons(playerid); UnFreeze(playerid); if(pInfo[playerid][JailTime] > 0) { SendClientMessage(playerid,COLOR_ERROR,\"Letöltetlen börtönbüntetés!\"); SendClientMessage(playerid,COLOR_ERROR,\"A börtönben ébredtél...\"); Jail(playerid,pInfo[playerid][JailTime]); } } else if(pInfo[playerid][Logins] == 0) { StartTutorial(playerid); }}}else{ new cart = CreateVehicle(449,-2264.6492,541.1763,35.1227,181.3010,0,0,-1);PutPlayerInVehicle(playerid,cart,0);}return 1;}
maxnpc 100 0
onplayerupdate