Witajcie, mam problem z kodem statsx

Chodzi mi mianowicie aby zrobic z tego
aby # Nick, Kill,Deat HS, ecc bvylo na niebiesko
1,2,3 itd było na niebiesko, a reszta poprostu napisow na biało
KOD PONIŻEJ
// Get and format top 15.
format_top15(sBuffer[MAX_BUFFER_LENGTH + 1])
{
new iMax = get_statsnum()
new izStats[8], izBody[8], istate[4]
new iLen = 0
if (iMax > 15)
iMax = 15
new lNick[16], lKills[16], lDeaths[16], lHs[16], lAcc[16]
format(lNick, 15, "%L", LANG_SERVER, "NICK_1")
format(lKills, 15, "%L", LANG_SERVER, "KILLS")
format(lDeaths, 15, "%L", LANG_SERVER, "DEATHS")
format(lHs, 15, "%L", LANG_SERVER, "HS_1")
format(lAcc, 15, "%L", LANG_SERVER, "ACC")
ucfirst(lAcc)
iLen = format( sBuffer, MAX_BUFFER_LENGTH,
"<head><META http-equiv=Content-Type content='text/html ;charset=UTF-8'></head><style>body{color:#6d077a;background-color:#11111a;margin-top:5}.A{background-color:##11111a}.B{background-color:#00ffff}td{font-size:14px}</style><center><b><font size=3>TOP15</b><table width=500>" )
iLen += format( sBuffer[iLen], MAX_BUFFER_LENGTH - iLen,
"<tr bgcolor=#9C0000><td>%s<td>%s<td>%s<td>%s<td>%s<td>%s",
"TOP", lNick, lKills, lDeaths, lHs, lAcc )
for (new i = 0; i < iMax && MAX_BUFFER_LENGTH - iLen > 0; i++)
{
if (equal(istate,"A")) copy(istate,3,"B")
else copy(istate,3,"A")
get_stats(i, izStats, izBody, t_sName, MAX_NAME_LENGTH)
while( contain ( t_sName, "<" ) != -1 )
replace( t_sName,MAX_BUFFER_LENGTH + 1,"<", "[" )
while( contain ( t_sName, ">" ) != -1 )
replace( t_sName,MAX_BUFFER_LENGTH + 1,">", "]" )
iLen += format(sBuffer[iLen], MAX_BUFFER_LENGTH - iLen, "<tr class=%s><td>%d<td>%s<td>%d<td>%d<td>%d<td>%0.2f%%",istate, i + 1, t_sName, izStats[STATS_KILLS],
izStats[STATS_DEATHS], izStats[STATS_HS], accuracy(izStats))
}
copy(sBuffer[iLen],MAX_BUFFER_LENGTH - iLen,"</table></br></br><hr size=1 color=#00ffff><p><b>TOP 15 by dwsxw23r</b></p>")
}
https://amxx.pl/topic/546-new-statsx/
Użytkownik KISIELkubabbvx edytował ten post 29.05.2021 12:49


Dodatki SourceMod



Temat jest zamknięty









