hello. i have this code
PHP Code:
replace_all(szTemp[id], charsmax(szTemp[]), ":", " ")
parse(szTemp[id], szHoursTemp[id], charsmax(szHoursTemp[]), szMinutesTemp[id], charsmax(szMinutesTemp[]), szSecondsTemp[id], charsmax(szSecondsTemp[]))
iHoursTemp[id] = str_to_num(szHoursTemp[id]) + g_iPlayedTime[id][Hours]
iMinutesTemp[id] = str_to_num(szMinutesTemp[id]) + g_iPlayedTime[id][Minutes]
iSecondsTemp[id] = str_to_num(szSecondsTemp[id]) + g_iPlayedTime[id][Seconds]
server_print("%i %i %i", iHoursTemp[id], iMinutesTemp[id], iSecondsTemp[id])
formatex(g_iPlayersInfo[id][PlayedTime], charsmax(g_iPlayersInfo[][PlayedTime]), "%s%i:%s%i:%s%i",
iHoursTemp[id] < 10 ? "0" : "", iHoursTemp[id], iMinutesTemp[id] < 10 ? "0" : "",
iMinutesTemp[id], iSecondsTemp[id] < 10 ? "0" : "", iSecondsTemp[id])
i'm trying to get the time. the problem is that the format is 00:00:00 (example of 5 hours, 14 mins and 7 second: 05:14:07)
The problem is that i think i can t use str_to_num like that (i mean to use it for a number like 05 or 07). some ideas ?