Jump to content

[Duda] setTimer


Mixters

Recommended Posts

Posted

Podes usar esta funcion que cree:

function convertTime ( ms ) 
    if ( ms and type ( ms ) == "number" ) then 
        local sec = math.floor ( ms / 1000 ) 
        local ms = ( ms % 1000 ) 
  
        local mins = math.floor ( sec / 60 ) 
        local sec = ( sec % 60 ) 
  
        local hours = math.floor ( mins / 60 ) 
        local mins = ( mins % 60 ) 
  
        local days = math.floor ( hours / 24 ) 
        local hours = ( hours % 24 ) 
  
        return days, hours, mins, sec 
    else 
        return 0, 0, 0, 0 
    end 
end 

Convierte milisegundos en dias, horas, minutos, segundos.

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Posted
O.....

60000 = a 1Min... y usas la Calculadora para saber cuanto quieres...

Haha, si ya entendi la wea :P

simplemente le agrego 000 a la cantidad en segundos, y ya :P

Scripter: 5% / 100%

En Conocimientos.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...