Code LAG problem!
#1

This code can cause lag with 20 players in vehicle in one time?

Код:
public OnPlayerExitVehicle(playerid, vehicleid)
{
	if(Car[vehicleid][vKm] > Car[vehicleid][vOldKm])
	{
	  	mysql_Query("UPDATE `fr_car` SET `Km` = '%f' WHERE `fr_car`.`ID` = %d LIMIT 1", Car[vehicleid][vKm], Car[vehicleid][vID]);
	   	Car[vehicleid][vOldKm] = Car[vehicleid][vKm];
	}
	return 1;
}
Use strickenkid mysql plugin
Reply
#2

UP!!!!!!!!!!
Reply
#3

No.

The message you have entered is too short. Please lengthen your message to at least 4 characters.
Reply
#4

Even if the script did connect 20 times to your database, it wouldn't cause any lag. It's unlikely that 20 players will exit there vehicle at the same time!
Reply
#5

Quote:
Originally Posted by linuxthefish
Посмотреть сообщение
Even if the script did connect 20 times to your database, it wouldn't cause any lag. It's unlikely that 20 players will exit there vehicle at the same time!
As he said
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)