Textdraws stop showing after some time, like speedometer stops beeing showed after 3-4 hours of playing... REP ++ -
buburuzu19 - 09.10.2014
The title says all my problem , after 15-20+ players , the textdraws aren't showing anymore.And i putted to destroy all the textdraws on disconnect to don't reach the limit of textdraws..
My OnPlayerDisconnect:
pawn Код:
public OnPlayerDisconnect(playerid, reason)
{
#if defined DEBUG
printf("[debug] OnPlayerDisconnect(%d, %d)", playerid, reason);
#endif
SetPlayerName(playerid, playerVariables[playerid][pNormalName]);
TextDrawDestroy(Linie[playerid]);
TextDrawDestroy(ButonInapoi[playerid]);
TextDrawDestroy(ButonUrmator[playerid]);
TextDrawDestroy(DealerMasina[playerid]);
TextDrawDestroy(DealerPret[playerid]);
TextDrawDestroy(ButonCumpara[playerid]);
TextDrawDestroy(ButonTesteaza[playerid]);
TextDrawDestroy(ButonAnuleaza[playerid]);
TextDrawDestroy(tTimer[playerid]);
TextDrawDestroy(DMV1[playerid]);
TextDrawDestroy(DMV2[playerid]);
TextDrawDestroy(TUT69[playerid]);
Ongamemodeexit:
pawn Код:
public OnGameModeExit() {
#if defined DEBUG
print("[debug] OnGameModeExit()");
#endif
KillTimer(unjailtimer);
KillTimer(messtimer);
KillTimer(findtimer);
KillTimer(checkcartimer);
KillTimer(checkgastimer);
new x;
while(x < MAX_TIMERS) {
KillTimer(scriptTimers[x]);
x++;
}
mysql_close(databaseConnection);
TextDrawDestroy(Time);
TextDrawDestroy(Date);
TextDrawDestroy(Textdraw1);
TextDrawDestroy(Textdraw0);
TextDrawDestroy(Textdraw2);
TextDrawDestroy(Textdraw3);
TextDrawDestroy(Textdraw4);
TextDrawDestroy(Textdraw5);
return 1;
}
Those all my textdraws..
Re: Textdraws stop showing after some time, like speedometer stops beeing showed after 3-4 hours of playing... REP ++ -
Rudy_ - 09.10.2014
Are you using TextDrawShowForPlayer or TextDrawShowForAll ?
Re: Textdraws stop showing after some time, like speedometer stops beeing showed after 3-4 hours of playing... REP ++ -
buburuzu19 - 09.10.2014
TextDrawShowForPlayer
Re: Textdraws stop showing after some time, like speedometer stops beeing showed after 3-4 hours of playing... REP ++ -
Rudy_ - 09.10.2014
Then use
https://sampwiki.blast.hk/wiki/TextDrawHideForPlayer
Re: Textdraws stop showing after some time, like speedometer stops beeing showed after 3-4 hours of playing... REP ++ -
buburuzu19 - 09.10.2014
I putted but i get now
pawn Код:
F:xxxxxxxxxxxxxxx\3.0.pwn(11502) : warning 213: tag mismatch
F:xxxxxxxxxxxxxxx(11502) : warning 202: number of arguments does not match definition
F:xxxxxxxxxxxxxxx(11503) : warning 213: tag mismatch
F:xxxxxxxxxxxxxxx(11503) : warning 202: number of arguments does not match definition
F:xxxxxxxxxxxxxxx(11504) : warning 213: tag mismatch
F:xxxxxxxxxxxxxxx(11504) : warning 202: number of arguments does not match definition
F:xxxxxxxxxxxxxxx(11505) : warning 213: tag mismatch
F:xxxxxxxxxxxxxxx(11505) : warning 202: number of arguments does not match definition
F:xxxxxxxxxxxxxxx(11506) : warning 213: tag mismatch
F:xxxxxxxxxxxxxxx(11506) : warning 202: number of arguments does not match definition
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
I think the textdraws reach the limit of showing, any ideeas?
Re: Textdraws stop showing after some time, like speedometer stops beeing showed after 3-4 hours of playing... REP ++ -
Rudy_ - 09.10.2014
Nope
TextDrawHideForPlayer(playerid, Textdraw[playerid]);
Edit: Just use
PlayerTextDrawDestroy instead...
Re: Textdraws stop showing after some time, like speedometer stops beeing showed after 3-4 hours of playing... REP ++ -
buburuzu19 - 09.10.2014
I used textdrawhideforplayer, i will put the gm on host to see what happens..