21.01.2017, 21:22
Please help me
Quote:
[debug] AMX backtrace: [debug] #0 00000032 in ?? (0x00000034, 0x00000000, 0x5883db06, 0x00000000, 0x00000061, 0x00000063, 0x00000063, 0x0000006f, 0x00000075, 0x0000006e, ... <4 arguments>) from nf.amx [debug] #1 00000032 in public FC_OnPlayerDisconnect () from nf.amx [debug] #2 native CallLocalFunction () [080dfac0] from samp03svr [debug] #3 00035610 in public SSCANF_OnPlayerDisconnect (0x00000007, 0x00000001) from nf.amx [debug] #4 000234ec in public Itter_OnPlayerDisconnect (0x00000007, 0x00000001) from nf.amx [debug] #5 000182e4 in ?? (0x00000007, 0x00000001) from nf.amx [debug] #6 000098e4 in public Streamer_OnPlayerDisconnect (0x00000007, 0x00000001) from nf.amx [debug] #7 native CallLocalFunction () [080dfac0] from samp03svr [debug] #8 000024d4 in public OnPlayerDisconnect (0x00000007, 0x00000001) from nf.amx |
Quote:
public OnPlayerDisconnect(playerid, reason) { //****sistema afk*** Afk[playerid]=0; TextDrawHideForPlayer(playerid,Text:Messageafk); KillTimer(Timer[playerid]); //**security** Jugadores = IDMayor(playerid); if(BotServidor[playerid]) BotServidor[playerid] = false; if (PlayerVelocimetro[playerid]) { KillTimer(PlayerVelocimetroTimer[playerid]); } if(Barra[playerid] != -1) { KillTimer(Barra[playerid]); Barra[playerid] = -1; } Advertencias[playerid] = 0; //************ if(GetPVarType(playerid, "PlacedBB")) { DestroyDynamicObject(GetPVarInt(playerid, "PlacedBB")); DestroyDynamic3DTextLabel(Text3D:GetPVarInt(player id, "BBLabel")); if(GetPVarType(playerid, "BBArea")) { foreach(Player,i) { if(IsPlayerInDynamicArea(i, GetPVarInt(playerid, "BBArea"))) { StopAudioStreamForPlayer(i); SendClientMessage(i, COLOR_WHITE, "* La mъsica deja de sonar ((El propietario de la {00AFED}boombox{FFFFFF} se ha desconectado))."); } } } } TextDrawHideForPlayer(playerid, Experiencia[playerid]); //sistema experiencia// new plname[MAX_PLAYER_NAME]; Delete3DTextLabel(estado[playerid]); GetPlayerName(playerid, plname, sizeof(plname)); if(!strcmp(plname, "BannedPlayer", true)) return 1; if(!strcmp(plname, "InvalidNick", true)) return 1; if(playerid == MAX_PLAYERS) return 1; if(GetPVarInt(playerid, "TempName") == 1) { new name[MAX_PLAYER_NAME]; GetPVarString(playerid, "TempNameName", name, sizeof(name)); SetPlayerName(playerid, name); SetPVarInt(playerid, "TempName", 0); } if(Info[playerid][pWExists] == 1) { WeedLogout(playerid); } if(pTazer[playerid] == 1) GivePlayerValidWeapon(playerid,pTazerReplace[playerid]); if(GetPVarInt(playerid, "Injured") == 1) { Info[playerid][pHospital] = 1; KillEMSQueue(playerid); ResetPlayerWeaponsEx(playerid); } if(Info[playerid][pLockCar] != INVALID_VEHICLE_ID) { vehicle_unlock_doors(Info[playerid][pLockCar]); } if(Info[playerid][pVehicleKeysFrom] != INVALID_PLAYER_ID) { PlayerVehicleInfo[Info[playerid][pVehicleKeysFrom]][Info[playerid][pVehicleKeys]][pvAllowedPlayerId] = INVALID_PLAYER_ID; } new string[128]; switch (reason) { case 0: { format(string, sizeof(string), "%s ha salido del servidor (Posible Crash).", GetPlayerNameEx(playerid)); ProxDetector(8.0, playerid, string, COLOR_YELLOW,COLOR_YELLOW,COLOR_YELLOW,COLOR_YELLO W,COLOR_YELLOW); if(Info[playerid][pEstado] == 2) { Info[playerid][pJailed] = 1; Info[playerid][pJailTime] += 20*60; } if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER) { for(new d = 0 ; d < MAX_PLAYERVEHICLES; d++) { if(IsPlayerInVehicle(playerid, PlayerVehicleInfo[playerid][d][pvId])) { new Float, Float:y, Float:z, Float:angle, vw; vw = GetPlayerVirtualWorld(playerid); GetVehiclePos(PlayerVehicleInfo[playerid][d][pvId], x, y, z); GetVehicleZAngle(PlayerVehicleInfo[playerid][d][pvId], angle); PlayerVehicleInfo[playerid][d][pvPosX] = x; PlayerVehicleInfo[playerid][d][pvPosY] = y; PlayerVehicleInfo[playerid][d][pvPosZ] = z; PlayerVehicleInfo[playerid][d][pvPosAngle] = angle; PlayerVehicleInfo[playerid][d][pvVW] = vw; } } } } case 1: { format(string, sizeof(string), "%s ha salido del servidor (Abandono).", GetPlayerNameEx(playerid)); ProxDetector(8.0, playerid, string, COLOR_YELLOW,COLOR_YELLOW,COLOR_YELLOW,COLOR_YELLO W,COLOR_YELLOW); if(Info[playerid][pEstado] == 2) { Info[playerid][pJailed] = 1; Info[playerid][pJailTime] += 20*60; } } case 2: { format(string, sizeof(string), "%s ha salido del servidor (Kick/Ban).", GetPlayerNameEx(playerid)); ProxDetector(8.0, playerid, string, COLOR_YELLOW,COLOR_YELLOW,COLOR_YELLOW,COLOR_YELLO W,COLOR_YELLOW); } } if(InfoEvento[EventRequest] == playerid) { InfoEvento[EventRequest] = 999; ABroadCast( COLOR_GENERAL, "Info: El jugador que estaba solicitando un evento se ha desconectado o crasheу.", 4 ); } if(InfoEvento[EventCreator] == playerid) { InfoEvento[EventCreator] = 999; ABroadCast( COLOR_GENERAL, "Info: El jugador que creу el evento se ha desconectado o crasheу.", 4 ); } if(InfoEvento[EventStaff][0] == playerid) { InfoEvento[EventStaff][0] = 999; } else if(InfoEvento[EventStaff][1] == playerid) { InfoEvento[EventStaff][1] = 999; } else if(InfoEvento[EventStaff][2] == playerid) { InfoEvento[EventStaff][2] = 999; } else if(InfoEvento[EventStaff][3] == playerid) { InfoEvento[EventStaff][3] = 999; } else if(InfoEvento[EventStaff][4] == playerid) { InfoEvento[EventStaff][4] = 999; } if(GetPVarInt(playerid, "IsInArena") == 1) { PaintballDisconnect(playerid); Info[playerid][pPos_x] = GetPVarFloat(playerid, "pbOldX"); Info[playerid][pPos_y] = GetPVarFloat(playerid, "pbOldY"); Info[playerid][pPos_z] = GetPVarFloat(playerid, "pbOldZ"); Info[playerid][pInt] = GetPVarInt(playerid, "pbOldInt"); Info[playerid][pVW] = GetPVarInt(playerid, "pbOldVW"); Info[playerid][pHealth] = GetPVarFloat(playerid, "pbOldHealth"); Info[playerid][pArmour] = GetPVarFloat(playerid, "pbOldArmor"); SetHP(playerid,GetPVarFloat(playerid, "pbOldHealth")); SetPlayerArmour(playerid,GetPVarFloat(playerid, "pbOldArmor")); } else if(GetPVarInt(playerid, "EventToken") == 0) { new Float: x, Float: y, Float: z; GetPlayerPos(playerid, x, y, z); Info[playerid][pPos_x] = x; Info[playerid][pPos_y] = y; Info[playerid][pPos_z] = z; GetPlayerFacingAngle(playerid, Info[playerid][pPos_r]); Info[playerid][pInt] = GetPlayerInterior(playerid); Info[playerid][pVW] = GetPlayerVirtualWorld(playerid); Info[playerid][pChar] = GetPlayerSkin(playerid); if(Info[playerid][pChar] == 0) Info[playerid][pChar] = 299; } else if(GetPVarInt(playerid, "EventToken") == 1) { Info[playerid][pInt] = EventLastInt[playerid]; Info[playerid][pVW] = EventLastVW[playerid]; Info[playerid][pChar] = Info[playerid][pChar]; Info[playerid][pPos_r] = EventFloats[playerid][0]; Info[playerid][pPos_x] = EventFloats[playerid][1]; Info[playerid][pPos_y] = EventFloats[playerid][2]; Info[playerid][pPos_z] = EventFloats[playerid][3]; } else if(ShowRules[playerid] == 1) { Info[playerid][pVW] = GetPVarInt(playerid, "rOldVW"); Info[playerid][pInt] = GetPVarInt(playerid, "rOldInt"); Info[playerid][pPos_x] = GetPVarFloat(playerid, "rOldX"); Info[playerid][pPos_y] = GetPVarFloat(playerid, "rOldY"); Info[playerid][pPos_z] = GetPVarFloat(playerid, "rOldZ"); } if(Spectate[playerid] < 553) { Info[playerid][pInt] = GetPVarInt(playerid, "SpecInt"); Info[playerid][pVW] = GetPVarInt(playerid, "SpecVW"); Info[playerid][pPos_x] = GetPVarFloat(playerid, "SpecPosX"); Info[playerid][pPos_y] = GetPVarFloat(playerid, "SpecPosY"); Info[playerid][pPos_z] = GetPVarFloat(playerid, "SpecPosZ"); GettingSpectated[Spectate[playerid]] = 999; Spectate[playerid] = 999; } if(Info[playerid][pAdverID] != -1) ClearAd(Info[playerid][pAdverID]); if(HireKey[playerid] != 9999) { SetVehicleToRespawn(HireKey[playerid]); } if(Interview != 0) { if(strcmp(Interviewer,plname,true) == 0 ) { SendClientMessageEx(playerid, COLOR_WHITE, "Se cancelу tu entrevista."); Interviewer = "Nadie"; Interview = 0; } } OnPlayerSavedStats(playerid); UnloadPlayerVehicles(playerid); ResetPlayerWeapons(playerid); for(new i = 0; i < MAX_REPORTS; i++) { if(Reports[i][ReportFrom] == playerid) { Reports[i][ReportFrom] = 999; Reports[i][BeingUsed] = 0; Reports[i][TimeToExpire] = 0; } } foreach(Player, i) { if(TaxiAccepted[i] == playerid) { TaxiAccepted[i] = 999; GameTextForPlayer(i, "~w~jugador~n~~r~se desconecto", 5000, 1); TaxiCallTime[i] = 0; DisablePlayerCheckpoint(i); } if(EMSAccepted[i] == playerid) { EMSAccepted[i] = 999; GameTextForPlayer(i, "~w~Jugador~n~~r~se desconecto", 5000, 1); EMSCallTime[i] = 0; DisablePlayerCheckpoint(i); } if(MedicAccepted[i] == playerid) { TaxiAccepted[playerid] = 999; MedicAccepted[playerid] = 999; GameTextForPlayer(i, "~w~Jugador~n~~r~se desconecto", 5000, 1); MedicCallTime[i] = 0; DisablePlayerCheckpoint(i); } } if(TransportCost[playerid] > 0 && TransportDriver[playerid] < 999) { if(IsPlayerConnected(TransportDriver[playerid])) { TransportMoney[TransportDriver[playerid]] += TransportCost[playerid]; TransportTime[TransportDriver[playerid]] = 0; TransportCost[TransportDriver[playerid]] = 0; format(string, sizeof(string), "~w~Pasajero se fue~n~~g~ganaste $%d",TransportCost[playerid]); GameTextForPlayer(TransportDriver[playerid], string, 5000, 1); TransportDriver[playerid] = 999; } } if(GotHit[playerid] > 0) { if(GetChased[playerid] < 999) { if(IsPlayerConnected(GetChased[playerid])) { SendClientMessageEx(GetChased[playerid], COLOR_YELLOW, "Tu hit saliу del servidor."); GoChase[GetChased[playerid]] = 999; } } } if(GoChase[playerid] < 999){ GetChased[GoChase[playerid]] = 999; GotHit[GoChase[playerid]] = 999; } if(GetPVarInt(playerid, "AdvisorDuty") == 1) { Advisors--; } if(Team_Mecanicos(playerid)) { if(OnDuty[playerid] == 1) { Mechanics -= 1; } } if(TransportDuty[playerid] == 1) { TaxiDrivers -= 1; } SetPVarInt(playerid,"Miner", 0); SetPVarInt(playerid,"Start", 0); if(BOMBA[playerid]){DestroyObject(BOMBA[playerid]);} MoneyBet[playerid] = 0; BetOnHorse[playerid] = 0; Watching[playerid] = 0; return 1; } |