2021-02-27, 08:57 PM
Espa?ol: Hola, tengo un Ranking de equipos en el cual si un jugador mata a otro jugador se le dar? de puntaje?al team, el problema es que cuando reinicio el servidor cuando?un jugador mata a otro jugador la puntuaci?n del team vuelve a 1 y va sumando nuevamente, en la base de datos se?guarda bien el puntaje del team pero se pierde cuando se suma nuevamente, debe ser por esta funci?n que quiz?s est? mal.
English: Hello, I have a Team Ranking in which if a player kills another player, the team will be given score, the problem is that when I restart the server when a player kills another player, the team score returns to 1 and it is adding again, in the database the team's score is saved well but it is lost when it is added again, it must be because of this function that it may be wrong.
Espa?ol:?O cual ser?a la soluci?n?
English:?Or what would be the solution?
English: Hello, I have a Team Ranking in which if a player kills another player, the team will be given score, the problem is that when I restart the server when a player kills another player, the team score returns to 1 and it is adding again, in the database the team's score is saved well but it is lost when it is added again, it must be because of this function that it may be wrong.
Code:
new query[250],puntaje;
puntaje?= 1;
mysql_format(con, query, sizeof query, "UPDATE `Ranking` SET `Score` = '%d' WHERE `ID` = '1'", puntaje);
mysql_query(con, query);
Espa?ol:?O cual ser?a la soluci?n?
English:?Or what would be the solution?
Programador b?sico