Zaloguj się by uzyskać pełen dostęp. Nie masz jeszcze konta? Założ je już teraz w kilka sekund.
GTAONLINE.PL
Tematy otagowane jako: laguje
1. Skrypt laguje
Witam, mam problem.
Po odpaleniu tego skryptu strasznie ro?nie u?ycie ramu oraz u?ycie procesora a nawet bardzo.
Da si? to naprawi?? pozdrawiam
[lua]--[[
©️ Copyright 2021, wszelkie prawa zastrze?one. Autor: Lucky
--]]

local sw,sh = guiGetScreenSize()
sx = function(value) return sw*value/1920 end
sy = function(value) return sh*value/1080 end

local screenW, screenH = guiGetScreenSize()

--local frequency = 1

addEventHandler('onClientResourceStart',root,function()
textures = {
['bg'] = dxCreateTexture('img/bg.png','argb',true,'clamp'),
['lgbt'] = dxCreateTexture('img/lgbt.png','argb',true,'clamp'),
['piesek'] = dxCreateTexture('img/piesek.png','argb',true,'clamp'),
['kizo'] = dxCreateTexture('img/kizo.png','argb',true,'clamp'),
['twojstary'] = dxCreateTexture('img/twojstary.png','argb',true,'clamp'),
['twojstaryrgb'] = dxCreateTexture('img/twojstaryrgb.png','argb',true,'clamp'),
['twojstary2rgb'] = dxCreateTexture('img/twojstary2rgb.png','argb',true,'clamp'),
['twojstary2'] = dxCreateTexture('img/twojstary2.png','argb',true,'clamp'),
['rgb'] = dxCreateTexture('img/rgb.png','argb',true,'clamp'),
['minionek'] = dxCreateTexture('img/minionek.png','argb',true,'clamp'),
['bg2'] = dxCreateTexture('img/bg2.png','argb',true,'clamp'),
['fuel'] = dxCreateTexture('img/fuel.png','argb',true,'clamp'),
['bateria'] = dxCreateTexture('img/bateria.png','argb',true,'clamp'),
['arrow'] = dxCreateTexture('img/arrow.png','ar...
2. Laguje mi serwer
wgralem paczke iyw potem pod??czy?em baze, wchodze do serwera loguje sie a tam takie lagi ze masakra

(prosze o pomoc krok po kroku poniewa? nie ogarniam takich rzeczy)

[ Dodano: 2018-06-08, 15:20 ]
Wy??czy?em gui i przesta?o lagowac, mo?e mi kto? wyt?umaczy? jak to zrobi? zeby przesta?o a zeby byl hud? albo moze mi ktos podeslac hud i gui tak zeby dzialalo?
3. skrypt Frakcja-policja laguje mi cały serwer
skrypt Frakcja-policja laguje mi ca?y serwer
a jak usune jeden z plik?w to nie dzia?a skrypt ja mam to naprawi??
4. Serwer sie laguje cały przy włączeniu panelui logwania,
Witam wi?c tak jak w temacie pow??czam ca?? skrypty i po chwili gdy w??czam panel logowania wszystko sie laguje i trzeba restart serwera bardzo prosz?o pomoc; .
5. [DM] SQLite laguje aż tak?
Czy mo?liwym jest, ?eby jedno zapytanie do SQLite zajmowa?o 400ms?

Kod:

[10] [join] asd has joined the server (0:dadas)
[10] SQLite UPDATE: 399ms
[10] [part] asd has left the server (0:1)


Kod:

new tick2 = GetTickCount();
new Query[256];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, sizeof name);
format(Query,sizeof(Query),"UPDATE `GRACZ` SET `KILLS` = '%d', `DEATHS` = '%d', `DAMAGE` = '%.0f', `EXP` = '%d',`EXPLEVEL` = '%d',`TOTALEXP` = '%d', `SKIN` = '%d', `WEATHER` = '%d', `TIME` = '%d' WHERE `NICK` = '%s'", PlayerKills[playerid], PlayerDeaths[playerid], TotalDamage[playerid], P_DATA[playerid][exp], P_DATA[playerid][explevel],P_DATA[playerid][totalexp], skin[playerid], weather[playerid], czas[playerid], name);
db_free_result(db_query(Konta, Query));
printf("SQLite UPDATE: %dms", GetTickCount() - tick2);


Da rade zoptymalizowa? czy jednak musze przej?? na inny system zapisu?