save time as integer