Jump to content

Question

Posted

Salut, stie cineva de ce am acest bug? adica imi pune in baza de date insurancepoints -1 chiar daca eu am pus sa dea --...


    if(vehicle_personal[vehicleid] > -1)
    {
        new id = vehicle_personal[vehicleid];

        PersonalVehicle[id][pvInsurancePoints] --;
        SCMF(id, -1, "DEBUG: %d", PersonalVehicle[id][pvInsurancePoints]);

        gQuery[0] = (EOS);
        mysql_format(SQL, gQuery, sizeof(gQuery), "UPDATE `server_personal_vehicles` SET `InsurancePoints` = '%d' WHERE `ID` = '%d'", PersonalVehicle[id][pvInsurancePoints], PersonalVehicle[id][pvID]);
        mysql_tquery(SQL, gQuery, "", "");
    }

 

si la debug scrie tot aia : -1

6 answers to this question

Recommended Posts

  • 0
Posted

 if(vehicle_personal[vehicleid] > -1 && PersonalVehicle[vehicleid][pvInsurancePoints] > 0)
    {
        new id = vehicle_personal[vehicleid];

        PersonalVehicle[id][pvInsurancePoints] --;
        SCMF(id, -1, "DEBUG: %d", PersonalVehicle[id][pvInsurancePoints]);

        gQuery[0] = (EOS);
        mysql_format(SQL, gQuery, sizeof(gQuery), "UPDATE `server_personal_vehicles` SET `InsurancePoints` = '%d' WHERE `ID` = '%d'", PersonalVehicle[id][pvInsurancePoints], PersonalVehicle[id][pvID]);
        mysql_tquery(SQL, gQuery, "", "");
    }

  • 0
Posted
54 minutes ago, hanako said:

 if(vehicle_personal[vehicleid] > -1 && PersonalVehicle[vehicleid][pvInsurancePoints] > 0)
    {
        new id = vehicle_personal[vehicleid];

        PersonalVehicle[id][pvInsurancePoints] --;
        SCMF(id, -1, "DEBUG: %d", PersonalVehicle[id][pvInsurancePoints]);

        gQuery[0] = (EOS);
        mysql_format(SQL, gQuery, sizeof(gQuery), "UPDATE `server_personal_vehicles` SET `InsurancePoints` = '%d' WHERE `ID` = '%d'", PersonalVehicle[id][pvInsurancePoints], PersonalVehicle[id][pvID]);
        mysql_tquery(SQL, gQuery, "", "");
    }

bro acm daca o explodez nu imi mai scade nimic

  • 0
Posted

incearca asa

if(vehicle_personal[vehicleid] > -1) 
    {
        new id = vehicle_personal[vehicleid];

        PersonalVehiclei[id][pvInsurancePoints]--;
        
        gQuery[0] = (EOS);
        mysql_format(SQL, gQuery, sizeof gQuery, "UPDATE `server_personal_vehicles` SET `Insurancepoints` = '%d' WHERE `ID` = '%d'", PersonalVehicle[id][pvInsurancePoints], PersonalVehicle[id][pvID]);
        mysql_tquery(SQL, gQuery, "", "");

        SCMf(getVehOwner(PersonalVehicle[id][pvOwnerID]), -1, "Vehiculul tau %s, a pierdut un punct de asigurare.", GetVehicleName(PersonalVehicle[id][pvModelID]));
    }
 

  • 0
Posted
7 minutes ago, hanako said:

incearca asa

if(vehicle_personal[vehicleid] > -1) 
    {
        new id = vehicle_personal[vehicleid];

        PersonalVehiclei[id][pvInsurancePoints]--;
        
        gQuery[0] = (EOS);
        mysql_format(SQL, gQuery, sizeof gQuery, "UPDATE `server_personal_vehicles` SET `Insurancepoints` = '%d' WHERE `ID` = '%d'", PersonalVehicle[id][pvInsurancePoints], PersonalVehicle[id][pvID]);
        mysql_tquery(SQL, gQuery, "", "");

        SCMf(getVehOwner(PersonalVehicle[id][pvOwnerID]), -1, "Vehiculul tau %s, a pierdut un punct de asigurare.", GetVehicleName(PersonalVehicle[id][pvModelID]));
    }
 

Multumesc. T/C

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • 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.