ID 0 Bug
#7

PHP код:
public OnPlayerConnect(playerid)
{
    if (
IsPlayerNPC(playerid))
        return 
1;
    if ((
GetTickCount() - PlayerData[playerid][pLeaveTime]) < 2000 && !strcmp(ReturnIP(playerid), PlayerData[playerid][pLeaveIP]))
    {
        
SendAdminAlert(COLOR_LIGHTRED"[ADMIN]: %s (%s) was kicked for possible rejoin hacks."ReturnName(playerid), ReturnIP(playerid));
        
Kick(playerid);
        return 
1;
    }
    new
        
str[128];
    
ResetPlayerWeapons(playerid);
    
SetPlayerArmedWeapon(playerid0);
    
PreloadAnimations(playerid);
    if (
g_ServerRestart) {
        
TextDrawShowForPlayer(playeridgServerTextdraws[3]);
    }
    for (new 
0!= MAX_PLAYER_ATTACHED_OBJECTS++) {
        
RemovePlayerAttachedObject(playeridi);
    }
    
// Gas pumps
    
RemoveBuildingForPlayer(playerid16761941.6563, -1767.289114.14066000.00);
    
RemoveBuildingForPlayer(playerid34652120.8203914.718811.25786000.00);
    
RemoveBuildingForPlayer(playerid1686, -1610.6172, -2721.000047.92976000.00);
    
// LS mall
    
RemoveBuildingForPlayer(playerid61301117.5859, -1490.007832.718810.0);
    
RemoveBuildingForPlayer(playerid62551117.5859, -1490.007832.718810.0);
    
RemoveBuildingForPlayer(playerid7621175.3594, -1420.187519.88280.25);
    
RemoveBuildingForPlayer(playerid6151166.3516, -1417.695313.95310.25);
    
// Sprunk machines
     
RemoveBuildingForPlayer(playerid13020.00.00.06000.0);
    
RemoveBuildingForPlayer(playerid12090.00.00.06000.0);
    
RemoveBuildingForPlayer(playerid9550.00.00.06000.0);
    
RemoveBuildingForPlayer(playerid9560.00.00.06000.0);
    
RemoveBuildingForPlayer(playerid17750.00.00.06000.0);
    
RemoveBuildingForPlayer(playerid17760.00.00.06000.0);
    
RemoveBuildingForPlayer(playerid19770.00.00.06000.0);
    
// Fire station
    
RemoveBuildingForPlayer(playerid7171703.9922, -1150.148423.09380.25);
    
RemoveBuildingForPlayer(playerid7171721.2344, -1150.148423.09380.25);
    
RemoveBuildingForPlayer(playerid13001715.4922, -1037.976623.26560.25);
    
RemoveBuildingForPlayer(playerid12941734.9531, -1156.992227.35160.25);
    
RemoveBuildingForPlayer(playerid7171738.7813, -1150.148423.09380.25);
    
RemoveBuildingForPlayer(playerid12271789.7734, -1116.062523.89060.25);
    
RemoveBuildingForPlayer(playerid12271789.9063, -1112.640623.89060.25);
    
RemoveBuildingForPlayer(playerid7171726.0000, -1064.882823.15630.25);
    
RemoveBuildingForPlayer(playerid46401728.7891, -1065.093824.50000.25);
    
RemoveBuildingForPlayer(playerid13001730.6328, -1033.671923.26560.25);
    
RemoveBuildingForPlayer(playerid45981737.2031, -1052.820323.33590.25);
    
RemoveBuildingForPlayer(playerid45991738.1875, -1044.992222.98440.25);
    
RemoveBuildingForPlayer(playerid13001747.8594, -1063.296923.26560.25);
    
RemoveBuildingForPlayer(playerid7171758.3828, -1066.359423.17970.25);
    
RemoveBuildingForPlayer(playerid13001758.0781, -1064.554723.26560.25);
    
RemoveBuildingForPlayer(playerid7171765.1563, -1042.523423.17970.25);
    
RemoveBuildingForPlayer(playerid13001764.8594, -1040.718823.26560.25);
    
RemoveBuildingForPlayer(playerid46411788.5391, -1026.351624.50000.25);
    
// Prison exterior
    
RemoveBuildingForPlayer(playerid3682247.92971461.859433.41410.25);
    
RemoveBuildingForPlayer(playerid3682192.27341456.125033.41410.25);
    
RemoveBuildingForPlayer(playerid3682199.75781397.882833.41410.25);
    
RemoveBuildingForPlayer(playerid3683133.74221356.992217.09380.25);
    
RemoveBuildingForPlayer(playerid3683166.78911356.992217.09380.25);
    
RemoveBuildingForPlayer(playerid3683166.78911392.156317.09380.25);
    
RemoveBuildingForPlayer(playerid3683133.74221392.156317.09380.25);
    
RemoveBuildingForPlayer(playerid3683166.78911426.914117.09380.25);
    
RemoveBuildingForPlayer(playerid3683133.74221426.914117.09380.25);
    
RemoveBuildingForPlayer(playerid3288221.57031374.96889.58590.25);
    
RemoveBuildingForPlayer(playerid3289212.07811426.03139.58590.25);
    
RemoveBuildingForPlayer(playerid3290218.25781467.53919.58590.25);
    
RemoveBuildingForPlayer(playerid3291246.56251435.19539.68750.25);
    
RemoveBuildingForPlayer(playerid3291246.56251410.53919.68750.25);
    
RemoveBuildingForPlayer(playerid3291246.56251385.89069.68750.25);
    
RemoveBuildingForPlayer(playerid3291246.56251361.24229.68750.25);
    
RemoveBuildingForPlayer(playerid3290190.91411371.77349.58590.25);
    
RemoveBuildingForPlayer(playerid3289183.74221444.86729.58590.25);
    
RemoveBuildingForPlayer(playerid3289222.50781444.69539.58590.25);
    
RemoveBuildingForPlayer(playerid3289221.17971390.29699.58590.25);
    
RemoveBuildingForPlayer(playerid3288223.17971421.18759.58590.25);
    
RemoveBuildingForPlayer(playerid3683133.74221459.640617.09380.25);
    
RemoveBuildingForPlayer(playerid3289207.53911371.24229.58590.25);
    
RemoveBuildingForPlayer(playerid3424220.64841355.18759.58590.25);
    
RemoveBuildingForPlayer(playerid3424221.70311404.50789.58590.25);
    
RemoveBuildingForPlayer(playerid3424210.41411444.84389.58590.25);
    
RemoveBuildingForPlayer(playerid3424262.50781465.20319.58590.25);
    
RemoveBuildingForPlayer(playerid3259220.64841355.18759.58590.25);
    
RemoveBuildingForPlayer(playerid3636133.74221356.992217.09380.25);
    
RemoveBuildingForPlayer(playerid3636166.78911356.992217.09380.25);
    
RemoveBuildingForPlayer(playerid3256190.91411371.77349.58590.25);
    
RemoveBuildingForPlayer(playerid3636166.78911392.156317.09380.25);
    
RemoveBuildingForPlayer(playerid3636133.74221392.156317.09380.25);
    
RemoveBuildingForPlayer(playerid3258207.53911371.24229.58590.25);
    
RemoveBuildingForPlayer(playerid3675205.64841394.132810.11720.25);
    
RemoveBuildingForPlayer(playerid3675205.64841392.156316.29690.25);
    
RemoveBuildingForPlayer(playerid3675205.64841394.132823.78130.25);
    
RemoveBuildingForPlayer(playerid3675207.35941390.570319.14840.25);
    
RemoveBuildingForPlayer(playerid3675206.50781387.851627.49220.25);
    
RemoveBuildingForPlayer(playerid3673199.75781397.882833.41410.25);
    
RemoveBuildingForPlayer(playerid3257221.57031374.96889.58590.25);
    
RemoveBuildingForPlayer(playerid3258221.17971390.29699.58590.25);
    
RemoveBuildingForPlayer(playerid3675203.95311409.914116.29690.25);
    
RemoveBuildingForPlayer(playerid3674199.38281407.117235.89840.25);
    
RemoveBuildingForPlayer(playerid3675204.64061409.851611.40630.25);
    
RemoveBuildingForPlayer(playerid3675206.50781404.234418.29690.25);
    
RemoveBuildingForPlayer(playerid3675206.50781400.656322.46880.25);
    
RemoveBuildingForPlayer(playerid3259221.70311404.50789.58590.25);
    
RemoveBuildingForPlayer(playerid3675207.35941409.000019.75780.25);
    
RemoveBuildingForPlayer(playerid3257223.17971421.18759.58590.25);
    
RemoveBuildingForPlayer(playerid3258212.07811426.03139.58590.25);
    
RemoveBuildingForPlayer(playerid3636166.78911426.914117.09380.25);
    
RemoveBuildingForPlayer(playerid3636133.74221426.914117.09380.25);
    
RemoveBuildingForPlayer(playerid3255246.56251361.24229.68750.25);
    
RemoveBuildingForPlayer(playerid3255246.56251385.89069.68750.25);
    
RemoveBuildingForPlayer(playerid3255246.56251410.53919.68750.25);
    
RemoveBuildingForPlayer(playerid3258183.74221444.86729.58590.25);
    
RemoveBuildingForPlayer(playerid3259210.41411444.84389.58590.25);
    
RemoveBuildingForPlayer(playerid3258222.50781444.69539.58590.25);
    
RemoveBuildingForPlayer(playerid16086232.28911434.484413.50000.25);
    
RemoveBuildingForPlayer(playerid3673192.27341456.125033.41410.25);
    
RemoveBuildingForPlayer(playerid3674183.03911455.750035.89840.25);
    
RemoveBuildingForPlayer(playerid3636133.74221459.640617.09380.25);
    
RemoveBuildingForPlayer(playerid3675196.02341462.015610.11720.25);
    
RemoveBuildingForPlayer(playerid3675198.00001462.015616.29690.25);
    
RemoveBuildingForPlayer(playerid3675196.02341462.015623.78130.25);
    
RemoveBuildingForPlayer(playerid3675180.24221460.320316.29690.25);
    
RemoveBuildingForPlayer(playerid3675180.30471461.007811.40630.25);
    
RemoveBuildingForPlayer(playerid3256218.25781467.53919.58590.25);
    
RemoveBuildingForPlayer(playerid3675199.58591463.726619.14840.25);
    
RemoveBuildingForPlayer(playerid3675181.15631463.726619.75780.25);
    
RemoveBuildingForPlayer(playerid3675185.92191462.875018.29690.25);
    
RemoveBuildingForPlayer(playerid3675202.30471462.875027.49220.25);
    
RemoveBuildingForPlayer(playerid3675189.50001462.875022.46880.25);
    
RemoveBuildingForPlayer(playerid3255246.56251435.19539.68750.25);
    
RemoveBuildingForPlayer(playerid3675254.67971451.828127.49220.25);
    
RemoveBuildingForPlayer(playerid3675253.82031458.109423.78130.25);
    
RemoveBuildingForPlayer(playerid3675255.53131454.546919.14840.25);
    
RemoveBuildingForPlayer(playerid3675253.82031456.132816.29690.25);
    
RemoveBuildingForPlayer(playerid3675253.82031458.109410.11720.25);
    
RemoveBuildingForPlayer(playerid3259262.50781465.20319.58590.25);
    
RemoveBuildingForPlayer(playerid3675254.67971468.210918.29690.25);
    
RemoveBuildingForPlayer(playerid3673247.92971461.859433.41410.25);
    
RemoveBuildingForPlayer(playerid3675254.67971464.632822.46880.25);
    
RemoveBuildingForPlayer(playerid3674247.55471471.093835.89840.25);
    
RemoveBuildingForPlayer(playerid3675255.53131472.976619.75780.25);
    
RemoveBuildingForPlayer(playerid3675252.81251473.828111.40630.25);
    
RemoveBuildingForPlayer(playerid3675252.12501473.890616.29690.25);
    
RemoveBuildingForPlayer(playerid16089342.12501431.09385.27340.25);
    
RemoveBuildingForPlayer(playerid16090315.77341431.09385.27340.25);
    
RemoveBuildingForPlayer(playerid16091289.74221431.09385.27340.25);
    
RemoveBuildingForPlayer(playerid16087358.67971430.453111.61720.25);
    
RemoveBuildingForPlayer(playerid16088368.42971431.09385.27340.25);
    
RemoveBuildingForPlayer(playerid16092394.15631431.09385.27340.25);
    
CancelSelectTextDraw(playerid);
    
GetPlayerIp(playeridPlayerData[playerid][pIP], 16);
    
GetPlayerName(playeridPlayerData[playerid][pUsername], MAX_PLAYER_NAME 1);
    
ResetStatistics(playerid);
    
CreateTextDraws(playerid);
    
format(strsizeof(str), "SELECT * FROM `blacklist` WHERE `Username` = '%s' OR `IP` = '%s'"ReturnName(playerid), PlayerData[playerid][pIP]);
    
mysql_tquery(g_iHandlestr"OnQueryFinished""dd"playeridTHREAD_BAN_LOOKUP);
    return 
1;

PHP код:
public OnPlayerDisconnect(playeridreason)
{
    
PlayerData[playerid][pLeaveTime] = GetTickCount();
    
format(PlayerData[playerid][pLeaveIP], 16PlayerData[playerid][pIP]);
     
TerminateConnection(playerid);
    return 
1;

PHP код:
stock TerminateConnection(playerid)
{
    if (
BoomboxData[playerid][boomboxPlaced])
        
Boombox_Destroy(playerid);
    if (
PlayerData[playerid][pRangeBooth] != -1)
        
Booth_Leave(playerid);
    if (
PlayerData[playerid][pFirstAid])
        
KillTimer(PlayerData[playerid][pAidTimer]);
    if (
PlayerData[playerid][pDrivingTest])
        
DestroyVehicle(PlayerData[playerid][pTestCar]);
    if (
PlayerData[playerid][pShowFooter])
        
KillTimer(PlayerData[playerid][pFooterTimer]);
    if (
PlayerData[playerid][pTaxiPlayer] != INVALID_PLAYER_ID)
        
LeaveTaxi(playeridPlayerData[playerid][pTaxiPlayer]);
    if (
PlayerData[playerid][pDragged])
        
KillTimer(PlayerData[playerid][pDragTimer]);
    if (
PlayerData[playerid][pFreeze])
        
KillTimer(PlayerData[playerid][pFreezeTimer]);
    foreach (new 
Player)
    {
        if (
PlayerData[i][pLastShot] == playerid) {
            
PlayerData[i][pLastShot] = INVALID_PLAYER_ID;
        }
        if (
PlayerData[i][pHouseSeller] == playerid) {
            
PlayerData[i][pHouseSeller] = INVALID_PLAYER_ID;
            
PlayerData[i][pHouseOffered] = -1;
        }
        if (
PlayerData[i][pBusinessSeller] == playerid) {
            
PlayerData[i][pBusinessSeller] = INVALID_PLAYER_ID;
            
PlayerData[i][pBusinessOffered] = -1;
        }
        if (
PlayerData[i][pCarSeller] == playerid) {
            
PlayerData[i][pCarSeller] = INVALID_PLAYER_ID;
            
PlayerData[i][pCarOffered] = -1;
        }
        if (
PlayerData[i][pShakeOffer] == playerid) {
            
PlayerData[i][pShakeOffer] = INVALID_PLAYER_ID;
            
PlayerData[i][pShakeType] = 0;
        }
        if (
PlayerData[i][pFriskOffer] == playerid) {
            
PlayerData[i][pFriskOffer] = INVALID_PLAYER_ID;
        }
        if (
PlayerData[i][pFoodSeller] == playerid) {
            
PlayerData[i][pFoodSeller] = INVALID_PLAYER_ID;
            
PlayerData[i][pFoodType] = 0;
        }
        if (
PlayerData[i][pFactionOffer] == playerid) {
            
PlayerData[i][pFactionOffer] = INVALID_PLAYER_ID;
            
PlayerData[i][pFactionOffered] = -1;
        }
        if (
PlayerData[i][pDraggedBy] == playerid) {
            
KillTimer(PlayerData[i][pDragTimer]);
            
PlayerData[i][pDragged] = 0;
            
PlayerData[i][pDraggedBy] = INVALID_PLAYER_ID;
        }
        if (
PlayerData[i][pMDCPlayer] == playerid) {
            
PlayerData[i][pMDCPlayer] = INVALID_PLAYER_ID;
            
PlayerData[i][pTrackTime] = 0;
        }
        if (
PlayerData[i][pNewsGuest] == playerid) {
            
PlayerData[i][pNewsGuest] = INVALID_PLAYER_ID;
        }
        if (
PlayerData[i][pGiveItem] == playerid) {
            
PlayerData[i][pGiveItem] = INVALID_PLAYER_ID;
        }
        if (
PlayerData[i][pTakeItems] == playerid) {
            
PlayerData[i][pTakeItems] = INVALID_PLAYER_ID;
        }
    }
    
SQL_SaveCharacter(playerid);
    
ResetNameTag(playerid);
    
Report_Clear(playerid);
    
ResetStatistics(playerid);
    return 
1;

Reply


Messages In This Thread
ID 0 Bug - by Varg - 16.09.2018, 14:10
Re: ID 0 Bug - by NoorMustafa123 - 16.09.2018, 18:11
Re: ID 0 Bug - by solstice_ - 16.09.2018, 18:48
Re: ID 0 Bug - by Florin48 - 16.09.2018, 18:54
Re: ID 0 Bug - by Varg - 16.09.2018, 19:01
Re: ID 0 Bug - by NoorMustafa123 - 16.09.2018, 19:06
Re: ID 0 Bug - by Varg - 16.09.2018, 19:12
Re: ID 0 Bug - by NoorMustafa123 - 16.09.2018, 19:13
Re: ID 0 Bug - by Varg - 16.09.2018, 20:12
Re: ID 0 Bug - by Shinja - 16.09.2018, 22:49

Forum Jump:


Users browsing this thread: 1 Guest(s)