• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Lua How to use just int not float number

luccagomes

New Member
Joined
Jul 30, 2015
Messages
153
Reaction score
1
How to use just number like a int, not like a float
Ex:
I want 1
Not 1.023902302

On this msg
Code:
    if (getPlayerStorageValue(cid, storages.delay) - os.time()) > 0 then
       talkState[talkUser] = 0   
       doPlayerPopupFYI(cid, 'You need wait '.. hour ..'h and '..minutes..'min. To finish another task (exp/skill)' )
       return true
     end
 
How to use just number like a int, not like a float
Ex:
I want 1
Not 1.023902302

On this msg
Code:
    if (getPlayerStorageValue(cid, storages.delay) - os.time()) > 0 then
       talkState[talkUser] = 0  
       doPlayerPopupFYI(cid, 'You need wait '.. hour ..'h and '..minutes..'min. To finish another task (exp/skill)' )
       return true
     end
You can use math.floor, Lua has no integer type, only double.
https://www.lua.org/pil/2.3.html
 
Back
Top