Jump to content

LeOn007

Membru
  • Posts

    35
  • Joined

  • Last visited

Posts posted by LeOn007

  1. Cauta in gamemode HTTP , daca gasesti ceva cu asta , sterge .

    Cauta in gamemode Ban si vezi unde-l gasesti , daca gasesti liber la playeri modifica.

    Schimba parola RCON sau fati sa-ti dea un mesaj cand cineva se logheaza .

  2. Problema intalnita (descriere): Plugin-ul crashdetect gaseste erori in OtherTimer ... am incercat orice si nu stiu ce sa mai fac
    Ero(area / rile) / warning-(ul / urile):

    [09:17:43] [debug] Run time error 4: "Array index out of bounds"
    [09:17:43] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:43] [debug] AMX backtrace:
    [09:17:43] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:44] [debug] Run time error 4: "Array index out of bounds"
    [09:17:44] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:44] [debug] AMX backtrace:
    [09:17:44] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:45] [debug] Run time error 4: "Array index out of bounds"
    [09:17:45] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:45] [debug] AMX backtrace:
    [09:17:45] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:46] [debug] Run time error 4: "Array index out of bounds"
    [09:17:46] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:46] [debug] AMX backtrace:
    [09:17:46] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:47] [debug] Run time error 4: "Array index out of bounds"
    [09:17:47] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:47] [debug] AMX backtrace:
    [09:17:47] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:48] [debug] Run time error 4: "Array index out of bounds"
    [09:17:48] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:48] [debug] AMX backtrace:
    [09:17:48] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:49] [debug] Run time error 4: "Array index out of bounds"
    [09:17:49] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:49] [debug] AMX backtrace:
    [09:17:49] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:50] [debug] Run time error 4: "Array index out of bounds"
    [09:17:50] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:50] [debug] AMX backtrace:
    [09:17:50] [debug] #0 00067320 in public OtherTimer () from RG.amx

    Liniile de cod / sursa / script-ul(obligatoriu):

    function OtherTimer()
    {
        new string[256];
        new Float:oldposx, Float:oldposy, Float:oldposz;
    for(new i = 0; i < MAX_PLAYERS; i++)
        {
       if(IsPlayerConnected(i))
       {
       new vehicleid = GetPlayerVehicleID(i);
    if(SafeTime > 0)
                {
                    SafeTime--;
                }
                if(SafeTime == 1)
                {
                    if(gPlayerAccount == 1 && gPlayerLogged == 0)
                    {
                    new loginname[256];
                        new loginstring[256];
                        GetPlayerName(i,loginname,sizeof(loginname));
                        format(loginstring,sizeof(loginstring),"{a9c4e4}Bun venit inapoi pe Reality-Gaming RPG n{a9c4e4}Cont:{008000} %s n{a9c4e4}Acest cont este inregistrat",loginname);
                        ShowPlayerDialog(i,12346,DIALOG_STYLE_PASSWORD,"Login",loginstring,"Login","Exit");
                    }
                }
           if(GetPlayerState(i) == 2)
           {
                    GetPlayerPos(i, TelePos[3], TelePos[4], TelePos[5]);
                    if(TelePos[5] > 550.0)
                    {
                        TelePos[0] = 0.0;
                        TelePos[1] = 0.0;
                    }
                    if(TelePos[0] != 0.0)
                    {
                        new distance = GetPlayerSpeed(i, true);
                        if ((BusrouteEast[0] == 0 && BusrouteWest[0] == 0))
                        {
                            if(gSpeedo == 2)
                            {
                                if(distance <10)
                                {
                                    format(string, sizeof(string), "~n~~g~mph : ~w~%.0f",distance);
                                }
                                if(distance > 10 && distance < 100)
                                {
                                    format(string, sizeof(string), "~n~~g~mph : ~w~%.0f",distance);
                                }
                                if(distance > 100)
                                {
                                    format(string, sizeof(string), "~n~~g~mph : ~w~%.0f",distance);
                                }
                                GameTextForPlayer(i, string, 2000, 5);
                            }
                        }
                    }
                    if(TelePos[5] < 550.0 && TelePos[3] != 0.0)
                    {
                        TelePos[0] = TelePos[3];
                        TelePos[1] = TelePos[4];
                    }
                }
           if(PlayerInfo[pLocal] != 255 && PlayerInfo[pInt] != 0)
                {
                    new house = PlayerInfo[pLocal];
                    GetPlayerPos(i, oldposx, oldposy, oldposz);
                    if(oldposz != 0.0)
                    {
                        if(oldposz < 600.0)
                        {
                            if(house == 242)
                            {
                           SetPlayerInterior(i,0);
                                SetPlayerPos(i,-2518.5967,-623.2701,132.7679);
                                PlayerInfo[pInt] = 0;
                                SetPlayerVirtualWorld(i,0);
                                PlayerInfo[pVirWorld] = 0;
                                PlayerInfo[pLocal] = 255;
                            }
                            else if(house < 175 && house != 10000)
                            {
                                SetPlayerPos(i, HouseInfo[house][hEntrancex], HouseInfo[house][hEntrancey],HouseInfo[house][hEntrancez]);
                                PlayerInfo[pLocal] = 255;
                                SetPlayerInterior(i,0);
                                SetPlayerVirtualWorld(i,0);
                                PlayerInfo[pVirWorld] = 0;
                                PlayerInfo[pInt] = 0;
                            }
                        }
                    }
                }
           if(CellTime > 0)
                {
                    if (CellTime == cchargetime)
                    {
                        CellTime = 1;
                        if(Mobile[Mobile] == i)
                        {
                            CallCost = CallCost+callcost;
                        }
                    }
                    CellTime = CellTime +1;
                    if (Mobile[Mobile] == 255 && CellTime == 5)
                    {
                   if(IsPlayerConnected(Mobile))
                   {
                            new called[MAX_PLAYER_NAME];
                            GetPlayerName(Mobile, called, sizeof(called));
                            format(string, sizeof(string), "* %s's phone rings.", called);
                            ProxDetector(30.0, Mobile, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
                            RingTone[Mobile] = 10;
                        }
                    }
                }
                if(CellTime == 0 && CallCost > 0)
                {
                    format(string, sizeof(string), "~w~The call cost~n~~r~%d EuroCent",CallCost);
                    GameTextForPlayer(i, string, 5000, 1);
                    new eurocenti = PlayerInfo[pEuroCent];
           PlayerInfo[pEuroCent] = eurocenti - CallCost;
                    SBizzInfo[2][sbTill] += CallCost;
                    ExtortionSBiz(2, CallCost);
                    CallCost = 0;
                }
                if(TransportTime > 0)
                {
               if(TransportTime >= 16)
                    {
                        TransportTime = 1;
                        if(TransportDriver < 999)
                        {
                            if(IsPlayerConnected(TransportDriver))
                            {
                           TransportCost += TransportValue[TransportDriver];
                           TransportCost[TransportDriver] = TransportCost;
                            }
                        }
                    }
               TransportTime += 1;
               format(string, sizeof(string), "~r~%d ~w~: ~g~%s",TransportTime,DecimalPoint(TransportCost));
               GameTextForPlayer(i, string, 1500, 6);
                if(GetPlayerMoney(i) < TransportCost)
            {
            format(string, sizeof(string), "* Ai nevoie de %s pentru a merge mai departe.", DecimalPoint(TransportCost));
                        SendClientMessage(i, COLOR_WHITE, string);
                        RemovePlayerFromVehicle(i);
                }
                }
                if (BusrouteEast[0] != 0 || BusrouteWest[0] != 0)
                {
                    if (!IsPlayerInAnyVehicle(i) || !IsABus(GetPlayerVehicleID(i)))
                    if (vehicleid != 0)
                    {
                        if (!IsABus(vehicleid))
                        {
                            if (BusrouteEast[0] != 0) BusrouteEnd(i, BusrouteEast[1]);
                            else if (BusrouteWest[0] != 0) BusrouteEnd(i, BusrouteWest[1]);
                        }
                    }
                    else
                    {
                        if (BusrouteEast[0] != 0) BusrouteEnd(i, BusrouteEast[1]);
                        else if (BusrouteWest[0] != 0) BusrouteEnd(i, BusrouteWest[1]);
                    }
                }
                if (IsABus(vehicleid) && GetPlayerState(i) == 2 && PlayerInfo[pJob] != 14)
                {
                    SetVehicleToRespawn(vehicleid);
                }
                if(IsAnOwnableCar(vehicleid) && GetPlayerState(i) == PLAYER_STATE_DRIVER)
                {
                    new Float:x, Float:y, Float:z;
                    GetVehiclePos(vehicleid, x, y, z);
                    new distance = GetDistances2(x, y, z, vPos[0][vehicleid], vPos[1][vehicleid], vPos[2][vehicleid]);
                    vPos[0][vehicleid] = x;
                    vPos[1][vehicleid] = y;
                    vPos[2][vehicleid] = z;
                    VehicleDistance[vehicleid] += distance;
                    if (VehicleDistance[vehicleid] > 370)
                    {
                        CarInfo[vehicleid][odometer]++;
                        VehicleDistance[vehicleid] = 0;
                    }
                }
            }
        }
        return 1;
    }

    Imagini / Video (optional):
    Ati incercat sa rezolvati singur?: DA :-(

     

     

    Am rezolvat , mersi oricum :-j . 2 Topic Closed si nici un raspuns . Buni MG mai sunteti.

     

     

    SOLVED

  3. MoveDynamicObject(objectid, Float:x, Float:y, Float:z, Float:speed, Float:rx = -1000.0, Float:ry = -1000.0, Float:rz = -1000.0);

     

     

    MoveDynamicObject(pdgate2,1546.8000000,-1625.6000000,13.6000000,4.0,0.0000000,0.0000000,270.0000000);

    pdgate2 = CreateDynamicObject(988,1546.8000000,-1625.6000000,13.6000000,0.0000000,0.0000000,270.0000000); //object(ws_apgate) (1)

  4. Salut .... Folosesc CrashDetect pe serverul meu si gasesc in GM erori fara numar , urmatoarele :

    [09:17:43] [debug] Run time error 4: "Array index out of bounds"
    [09:17:43] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:43] [debug] AMX backtrace:
    [09:17:43] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:44] [debug] Run time error 4: "Array index out of bounds"
    [09:17:44] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:44] [debug] AMX backtrace:
    [09:17:44] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:45] [debug] Run time error 4: "Array index out of bounds"
    [09:17:45] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:45] [debug] AMX backtrace:
    [09:17:45] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:46] [debug] Run time error 4: "Array index out of bounds"
    [09:17:46] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:46] [debug] AMX backtrace:
    [09:17:46] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:47] [debug] Run time error 4: "Array index out of bounds"
    [09:17:47] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:47] [debug] AMX backtrace:
    [09:17:47] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:48] [debug] Run time error 4: "Array index out of bounds"
    [09:17:48] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:48] [debug] AMX backtrace:
    [09:17:48] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:49] [debug] Run time error 4: "Array index out of bounds"
    [09:17:49] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:49] [debug] AMX backtrace:
    [09:17:49] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:50] [debug] Run time error 4: "Array index out of bounds"
    [09:17:50] [debug] Accessing element at index 255 past array upper bound 99
    [09:17:50] [debug] AMX backtrace:
    [09:17:50] [debug] #0 00067320 in public OtherTimer () from RG.amx

    Si tot apar iar si iar si iar .

     

    Acesta este codul :

    function OtherTimer()
    {
        new string[256];
        new Float:oldposx, Float:oldposy, Float:oldposz;
    for(new i = 0; i < MAX_PLAYERS; i++)
        {
         if(IsPlayerConnected(i))
         {
         new vehicleid = GetPlayerVehicleID(i);
    if(SafeTime > 0)
                {
                    SafeTime--;
                }
                if(SafeTime == 1)
                {
                    if(gPlayerAccount == 1 && gPlayerLogged == 0)
                    {
                    new loginname[256];
                        new loginstring[256];
                        GetPlayerName(i,loginname,sizeof(loginname));
                        format(loginstring,sizeof(loginstring),"{a9c4e4}Bun venit inapoi pe Reality-Gaming RPG n{a9c4e4}Cont:{008000} %s n{a9c4e4}Acest cont este inregistrat",loginname);
                        ShowPlayerDialog(i,12346,DIALOG_STYLE_PASSWORD,"Login",loginstring,"Login","Exit");
                    }
                }
             if(GetPlayerState(i) == 2)
             {
                    GetPlayerPos(i, TelePos[3], TelePos[4], TelePos[5]);
                    if(TelePos[5] > 550.0)
                    {
                        TelePos[0] = 0.0;
                        TelePos[1] = 0.0;
                    }
                    if(TelePos[0] != 0.0)
                    {
                        new distance = GetPlayerSpeed(i, true);
                        if ((BusrouteEast[0] == 0 && BusrouteWest[0] == 0))
                        {
                            if(gSpeedo == 2)
                            {
                                if(distance <10)
                                {
                                    format(string, sizeof(string), "~n~~g~mph : ~w~%.0f",distance);
                                }
                                if(distance > 10 && distance < 100)
                                {
                                    format(string, sizeof(string), "~n~~g~mph : ~w~%.0f",distance);
                                }
                                if(distance > 100)
                                {
                                    format(string, sizeof(string), "~n~~g~mph : ~w~%.0f",distance);
                                }
                                GameTextForPlayer(i, string, 2000, 5);
                            }
                        }
                    }
                    if(TelePos[5] < 550.0 && TelePos[3] != 0.0)
                    {
                        TelePos[0] = TelePos[3];
                        TelePos[1] = TelePos[4];
                    }
                }
             if(PlayerInfo[pLocal] != 255 && PlayerInfo[pInt] != 0)
                {
                    new house = PlayerInfo[pLocal];
                    GetPlayerPos(i, oldposx, oldposy, oldposz);
                    if(oldposz != 0.0)
                    {
                        if(oldposz < 600.0)
                        {
                            if(house == 242)
                            {
                             SetPlayerInterior(i,0);
                                SetPlayerPos(i,-2518.5967,-623.2701,132.7679);
                                PlayerInfo[pInt] = 0;
                                SetPlayerVirtualWorld(i,0);
                                PlayerInfo[pVirWorld] = 0;
                                PlayerInfo[pLocal] = 255;
                            }
                            else if(house < 175 && house != 10000)
                            {
                                SetPlayerPos(i, HouseInfo[house][hEntrancex], HouseInfo[house][hEntrancey],HouseInfo[house][hEntrancez]);
                                PlayerInfo[pLocal] = 255;
                                SetPlayerInterior(i,0);
                                SetPlayerVirtualWorld(i,0);
                                PlayerInfo[pVirWorld] = 0;
                                PlayerInfo[pInt] = 0;
                            }
                        }
                    }
                }
             if(CellTime > 0)
                {
                    if (CellTime == cchargetime)
                    {
                        CellTime = 1;
                        if(Mobile[Mobile] == i)
                        {
                            CallCost = CallCost+callcost;
                        }
                    }
                    CellTime = CellTime +1;
                    if (Mobile[Mobile] == 255 && CellTime == 5)
                    {
                     if(IsPlayerConnected(Mobile))
                     {
                            new called[MAX_PLAYER_NAME];
                            GetPlayerName(Mobile, called, sizeof(called));
                            format(string, sizeof(string), "* %s's phone rings.", called);
                            ProxDetector(30.0, Mobile, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
                            RingTone[Mobile] = 10;
                        }
                    }
                }
                if(CellTime == 0 && CallCost > 0)
                {
                    format(string, sizeof(string), "~w~The call cost~n~~r~%d EuroCent",CallCost);
                    GameTextForPlayer(i, string, 5000, 1);
                    new eurocenti = PlayerInfo[pEuroCent];
             PlayerInfo[pEuroCent] = eurocenti - CallCost;
                    SBizzInfo[2][sbTill] += CallCost;
                    ExtortionSBiz(2, CallCost);
                    CallCost = 0;
                }
                if(TransportTime > 0)
                {
                 if(TransportTime >= 16)
                    {
                        TransportTime = 1;
                        if(TransportDriver < 999)
                        {
                            if(IsPlayerConnected(TransportDriver))
                            {
                             TransportCost += TransportValue[TransportDriver];
                             TransportCost[TransportDriver] = TransportCost;
                            }
                        }
                    }
                 TransportTime += 1;
                 format(string, sizeof(string), "~r~%d ~w~: ~g~%s",TransportTime,DecimalPoint(TransportCost));
                 GameTextForPlayer(i, string, 1500, 6);
                if(GetPlayerMoney(i) < TransportCost)
            {
            format(string, sizeof(string), "* Ai nevoie de %s pentru a merge mai departe.", DecimalPoint(TransportCost));
                        SendClientMessage(i, COLOR_WHITE, string);
                        RemovePlayerFromVehicle(i);
                }
                }
                if (BusrouteEast[0] != 0 || BusrouteWest[0] != 0)
                {
                    if (!IsPlayerInAnyVehicle(i) || !IsABus(GetPlayerVehicleID(i)))
                    if (vehicleid != 0)
                    {
                        if (!IsABus(vehicleid))
                        {
                            if (BusrouteEast[0] != 0) BusrouteEnd(i, BusrouteEast[1]);
                            else if (BusrouteWest[0] != 0) BusrouteEnd(i, BusrouteWest[1]);
                        }
                    }
                    else
                    {
                        if (BusrouteEast[0] != 0) BusrouteEnd(i, BusrouteEast[1]);
                        else if (BusrouteWest[0] != 0) BusrouteEnd(i, BusrouteWest[1]);
                    }
                }
                if (IsABus(vehicleid) && GetPlayerState(i) == 2 && PlayerInfo[pJob] != 14)
                {
                    SetVehicleToRespawn(vehicleid);
                }
                if(IsAnOwnableCar(vehicleid) && GetPlayerState(i) == PLAYER_STATE_DRIVER)
                {
                    new Float:x, Float:y, Float:z;
                    GetVehiclePos(vehicleid, x, y, z);
                    new distance = GetDistances2(x, y, z, vPos[0][vehicleid], vPos[1][vehicleid], vPos[2][vehicleid]);
                    vPos[0][vehicleid] = x;
                    vPos[1][vehicleid] = y;
                    vPos[2][vehicleid] = z;
                    VehicleDistance[vehicleid] += distance;
                    if (VehicleDistance[vehicleid] > 370)
                    {
                        CarInfo[vehicleid][odometer]++;
                        VehicleDistance[vehicleid] = 0;
                    }
                }
            }
        }
        return 1;
    }
    new Float:vPos[3][MAX_VEHICLES]; // ---------------------------
    new VehicleDistance[MAX_VEHICLES]; // sunt definite cu MAX_VEHICLES

    Are cineva vreo idee de la ce ar putea fi ? X_X

  5. Salut .... Folosesc CrashDetect pe serverul meu si gasesc in GM erori fara numar , urmatoarele :

    [09:17:43] [debug] Run time error 4: "Array index out of bounds"
    [09:17:43] [debug]  Accessing element at index 255 past array upper bound 99
    [09:17:43] [debug] AMX backtrace:
    [09:17:43] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:44] [debug] Run time error 4: "Array index out of bounds"
    [09:17:44] [debug]  Accessing element at index 255 past array upper bound 99
    [09:17:44] [debug] AMX backtrace:
    [09:17:44] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:45] [debug] Run time error 4: "Array index out of bounds"
    [09:17:45] [debug]  Accessing element at index 255 past array upper bound 99
    [09:17:45] [debug] AMX backtrace:
    [09:17:45] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:46] [debug] Run time error 4: "Array index out of bounds"
    [09:17:46] [debug]  Accessing element at index 255 past array upper bound 99
    [09:17:46] [debug] AMX backtrace:
    [09:17:46] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:47] [debug] Run time error 4: "Array index out of bounds"
    [09:17:47] [debug]  Accessing element at index 255 past array upper bound 99
    [09:17:47] [debug] AMX backtrace:
    [09:17:47] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:48] [debug] Run time error 4: "Array index out of bounds"
    [09:17:48] [debug]  Accessing element at index 255 past array upper bound 99
    [09:17:48] [debug] AMX backtrace:
    [09:17:48] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:49] [debug] Run time error 4: "Array index out of bounds"
    [09:17:49] [debug]  Accessing element at index 255 past array upper bound 99
    [09:17:49] [debug] AMX backtrace:
    [09:17:49] [debug] #0 00067320 in public OtherTimer () from RG.amx
    [09:17:50] [debug] Run time error 4: "Array index out of bounds"
    [09:17:50] [debug]  Accessing element at index 255 past array upper bound 99
    [09:17:50] [debug] AMX backtrace:
    [09:17:50] [debug] #0 00067320 in public OtherTimer () from RG.amx
    

    Si tot apar iar si iar si iar .

     

    Acesta este codul :

    function OtherTimer()
    {
    	new string[256];
    	new Float:oldposx, Float:oldposy, Float:oldposz;
        for(new i = 0; i < MAX_PLAYERS; i++)
    	{
    	    if(IsPlayerConnected(i))
    	    {
    	        new vehicleid = GetPlayerVehicleID(i);
                if(SafeTime > 0)
    			{
    				SafeTime--;
    			}
    			if(SafeTime == 1)
    			{
    				if(gPlayerAccount == 1 && gPlayerLogged == 0)
    				{
        				new loginname[256];
    					new loginstring[256];
    					GetPlayerName(i,loginname,sizeof(loginname));
    					format(loginstring,sizeof(loginstring),"{a9c4e4}Bun venit inapoi pe Reality-Gaming RPG n{a9c4e4}Cont:{008000} %s n{a9c4e4}Acest cont este inregistrat",loginname);
    					ShowPlayerDialog(i,12346,DIALOG_STYLE_PASSWORD,"Login",loginstring,"Login","Exit");
    				}
    			}
    		    if(GetPlayerState(i) == 2)
    		    {
    				GetPlayerPos(i, TelePos[3], TelePos[4], TelePos[5]);
    				if(TelePos[5] > 550.0)
    				{
    					TelePos[0] = 0.0;
    					TelePos[1] = 0.0;
    				}
    				if(TelePos[0] != 0.0)
    				{
    					new distance = GetPlayerSpeed(i, true);
    					if ((BusrouteEast[0] == 0 && BusrouteWest[0] == 0))
    					{
    						if(gSpeedo == 2)
    						{
    							if(distance <10)
    							{
    								format(string, sizeof(string), "~n~~g~mph :   ~w~%.0f",distance);
    							}
    							if(distance > 10 && distance < 100)
    							{
    								format(string, sizeof(string), "~n~~g~mph :  ~w~%.0f",distance);
    							}
    							if(distance > 100)
    							{
    								format(string, sizeof(string), "~n~~g~mph : ~w~%.0f",distance);
    							}
    							GameTextForPlayer(i, string, 2000, 5);
    						}
    					}
    				}
    				if(TelePos[5] < 550.0 && TelePos[3] != 0.0)
    				{
    					TelePos[0] = TelePos[3];
    					TelePos[1] = TelePos[4];
    				}
    			}
    		    if(PlayerInfo[pLocal] != 255 && PlayerInfo[pInt] != 0)
    			{
    				new house = PlayerInfo[pLocal];
    				GetPlayerPos(i, oldposx, oldposy, oldposz);
    				if(oldposz != 0.0)
    				{
    					if(oldposz < 600.0)
    					{
    						if(house == 242)
    						{
    						    SetPlayerInterior(i,0);
    							SetPlayerPos(i,-2518.5967,-623.2701,132.7679);
    							PlayerInfo[pInt] = 0;
    							SetPlayerVirtualWorld(i,0);
    							PlayerInfo[pVirWorld] = 0;
    							PlayerInfo[pLocal] = 255;
    						}
    						else if(house < 175 && house != 10000)
    						{
    							SetPlayerPos(i, HouseInfo[house][hEntrancex], HouseInfo[house][hEntrancey],HouseInfo[house][hEntrancez]);
    							PlayerInfo[pLocal] = 255;
    							SetPlayerInterior(i,0);
    							SetPlayerVirtualWorld(i,0);
    							PlayerInfo[pVirWorld] = 0;
    							PlayerInfo[pInt] = 0;
    						}
    					}
    				}
    			}
    		    if(CellTime > 0)
    			{
    				if (CellTime == cchargetime)
    				{
    					CellTime = 1;
    					if(Mobile[Mobile] == i)
    					{
    						CallCost = CallCost+callcost;
    					}
    				}
    				CellTime = CellTime +1;
    				if (Mobile[Mobile] == 255 && CellTime == 5)
    				{
    				    if(IsPlayerConnected(Mobile))
    				    {
    						new called[MAX_PLAYER_NAME];
    						GetPlayerName(Mobile, called, sizeof(called));
    						format(string, sizeof(string), "* %s's phone rings.", called);
    						ProxDetector(30.0, Mobile, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
    						RingTone[Mobile] = 10;
    					}
    				}
    			}
    			if(CellTime == 0 && CallCost > 0)
    			{
    				format(string, sizeof(string), "~w~The call cost~n~~r~%d EuroCent",CallCost);
    				GameTextForPlayer(i, string, 5000, 1);
    				new eurocenti = PlayerInfo[pEuroCent];
    		        PlayerInfo[pEuroCent] = eurocenti - CallCost;
    				SBizzInfo[2][sbTill] += CallCost;
    				ExtortionSBiz(2, CallCost);
    				CallCost = 0;
    			}
    			if(TransportTime > 0)
    			{
    			    if(TransportTime >= 16)
    				{
    					TransportTime = 1;
    					if(TransportDriver < 999)
    					{
    						if(IsPlayerConnected(TransportDriver))
    						{
    	      					TransportCost += TransportValue[TransportDriver];
    						    TransportCost[TransportDriver] = TransportCost;
    						}
    					}
    				}
    			    TransportTime += 1;
    			    format(string, sizeof(string), "~r~%d ~w~: ~g~%s",TransportTime,DecimalPoint(TransportCost));
    			    GameTextForPlayer(i, string, 1500, 6);
           			if(GetPlayerMoney(i) < TransportCost)
              		{
                		format(string, sizeof(string), "* Ai nevoie de %s pentru a merge mai departe.", DecimalPoint(TransportCost));
    					SendClientMessage(i, COLOR_WHITE, string);
    					RemovePlayerFromVehicle(i);
         			}
    			}
    			if (BusrouteEast[0] != 0 || BusrouteWest[0] != 0)
    			{
    				if (!IsPlayerInAnyVehicle(i) || !IsABus(GetPlayerVehicleID(i)))
    				if (vehicleid != 0)
    				{
    					if (!IsABus(vehicleid))
    					{
    						if (BusrouteEast[0] != 0) BusrouteEnd(i, BusrouteEast[1]);
    						else if (BusrouteWest[0] != 0) BusrouteEnd(i, BusrouteWest[1]);
    					}
    				}
    				else
    				{
    					if (BusrouteEast[0] != 0) BusrouteEnd(i, BusrouteEast[1]);
    					else if (BusrouteWest[0] != 0) BusrouteEnd(i, BusrouteWest[1]);
    				}
    			}
    			if (IsABus(vehicleid) && GetPlayerState(i) == 2 && PlayerInfo[pJob] != 14)
    			{
    				SetVehicleToRespawn(vehicleid);
    			}
    			if(IsAnOwnableCar(vehicleid) && GetPlayerState(i) == PLAYER_STATE_DRIVER)
    			{
    				new Float:x, Float:y, Float:z;
    				GetVehiclePos(vehicleid, x, y, z);
    				new distance = GetDistances2(x, y, z, vPos[0][vehicleid], vPos[1][vehicleid], vPos[2][vehicleid]);
    				vPos[0][vehicleid] = x;
    				vPos[1][vehicleid] = y;
    				vPos[2][vehicleid] = z;
    				VehicleDistance[vehicleid] += distance;
    				if (VehicleDistance[vehicleid] > 370)
    				{
    					CarInfo[vehicleid][odometer]++;
    					VehicleDistance[vehicleid] = 0;
    				}
    			}
    		}
    	}
    	return 1;
    }
    
    new Float:vPos[3][MAX_VEHICLES]; // ---------------------------
    new VehicleDistance[MAX_VEHICLES]; // sunt definite cu MAX_VEHICLES

    Are cineva vreo idee de la ce ar putea fi ? X_X

  6. Server Crash ...

    Aveti aici parte din server.cfg

    [pawn]filterscripts JunkBuster af antibot

    plugins streamer.so sscanf.so

    maxnpc 1

    onfoot_rate 40

    incar_rate 40

    weapon_rate 40

    stream_distance 300.0

    stream_rate 1000[/pawn]

    Imi puteti spune va rog de la ce e :(

    Cand am incercat cu crashdetect imi zicea ca e de la JunkBuster.Amx dar nu imi dau seama de la ce exact ...

    Am incercat treaba cu zcmd si am modificat si in gamemode onplayercommandtext cu OnPlayerCommandPerformed ( playerid, cmdtext [ ] , success ).

    Tin sa mentionez ca la inceput nu aveam aceasta problema ... am patit asta la un momentdat cand firma de host mia dat un mesaj precum ca gamemodeu meu face prea multe descarcari pe secunda pentru un player.Am cautat si am cautat si am aflat ca trebuie sa modific onplayerupdate asa ca functia a devenit OnplayerupdateEx si cred ca de atunci a inceput totul dar daca readuc onplayerupdate iar umplu serverul de lag.

    Ce as putea face?:( [Rezolvat]

  7. Modifica :

    [pawn]if(CarData[newcar - PreVehicle][cOwned] == 1 && CarData[newcar - PreVehicle][cModel] >= 400 && CarData[newcar - PreVehicle][cModel] <= 611 && PreVehicle < newcar)

    {

    format(string, sizeof(string), "^^{FFFFFF}Acest vehicul: {A5FF23} [%s,TD: %d] {FFFFFF}apartine lui:{FE6235} %s.", ArIsim[GetVehicleModel(GetPlayerVehicleID(playerid))-500],CarData[newcar- PreVehicle][cExploded],CarData[newcar- PreVehicle][cOwner]);

    SendClientMessage(playerid, COLOR_BLUE, string);

    }[/pawn]

    Cu:

    [pawn]if(CarData[newcar - PreVehicle][cOwned] == 1 && CarData[newcar - PreVehicle][cModel] >= 400 && CarData[newcar - PreVehicle][cModel] <= 611 && PreVehicle < newcar)

    {

    format(string, sizeof(string), "^^{FFFFFF}Acest vehicul: {A5FF23} [%s,TD: %d] {FFFFFF}apartine lui:{FE6235} %s.", ArIsim[GetVehicleModel(GetPlayerVehicleID(playerid))-500],CarData[newcar- PreVehicle][cExploded],CarData[newcar- PreVehicle][cOwner]);

    SendClientMessage(playerid, COLOR_BLUE, string);

    GetPlayerName(playerid, sendername, sizeof(sendername));

                                    if(strcmp(sendername, CarInfo[newcar - PreVehicle][cOwner], true) == 0)

                                    {

                                    }

                                    else {

                                        RemovePlayerFromVehicle(playerid); return 1;}

    }[/pawn]

    Sper sa iti fie de folos.

  8. [pawn]if(IsAPlane(vehicle) || IsABoat(vehicle) || IsABmx(vehicle) || IsABus(vehicle) || TruckerCar(vehicle)) { Gas[vehicle]++; }[/pawn] Aici modifica cu asta

    [pawn]if(IsAPlane(vehicle) || IsABoat(vehicle) || IsABmx(vehicle) || IsABus(vehicle) || TruckerCar(vehicle) || engineOn[vehicle] == 0) { Gas[vehicle]++; }[/pawn]

  9. OnPlayerEnterRaceCheckpoint cauta acesta in includeurile pe care le ai.Vezi ca il folosesc 3 includeuri deodata.

    Cauta asta in GM GetPointDistanceToPointExMorph si sterge definita pentru ca nu-l foloseste.

    D:\A Doua Viata host\gamemodes\a2viata.pwn(16032) : warning 219: local variable "string" shadows a variable at a preceding level - aici ai definit de 2 ori stringu in acelasi CallBack.

    D:\A Doua Viata host\gamemodes\a2viata.pwn(27342) : warning 219: local variable "mod" shadows a variable at a preceding level - aici la fel.

  10. Salut,am primit un mesaj de la host si vas ruga daca se poate sa-l descifram impreuna ...

    Gamemode-ul dumneavoastra este defectuos, actualizand fisierele ini ale jucatorilor la fiecare tick (de cateva zeci de ori pe secunda, pentru fiecare jucator conectat) generand o incarcare majora pe partea HDD-ului si o scriere de 1.5 MB / s cand serverul are 50/100 de jucatori ... chestiunea asta afecteaza buna functionare a unitatii procesorale si nu mai putem gazdui in aceste conditii.

    Multumesc aniticipat !

    Saveaccounts are un timer de 20 de minute ... (1.200.000 milisecunde) , nu inteleg la ce sar putea referi :(

    Am sters acum 3 loguri care se incarcau mai mult ...

  11. Salut ... am o "mica mare" problema . Cand ajung la un numar de 60 de playeri pe server am un lag infernal desi folosesc streamer dar nu pe obiecte deoarece acestea dispar din cauza lagului si se formeaza bug.

    Aveti ideea ce se pot face?

  12. 1.Salut tuturor.Deci am si eu un GM si am incercat sa colorez pe harta gangurile.Am introdus in GM datele necesare dar in game nu apar colorate locurile.GM-ul nu da nici o eroare si acele date leam mai folosit si in alte GM-uri ... Stie cineva de la ce ar putea sa fie?

    2.Cum pot sa fac de exemplu daca esti intr-un loc anume x,y,z si omori pe cineva sa iei kick automat?

×
×
  • 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.