Пользовательские дополнения

На главную


common.GetMsFromDateTime( timeTable )

Возвращает Unix time (количество миллисекунд, прошедших с 1-го января 1970-го года), по дате и времени в формате типа LuaFullDateTime.

-- библиотека:
common

-- объявление:
function GetMsFromDateTime( timeTable )

-- параметры:
timeTable - таблица с полями:
 y: number (integer) - год
 m: number (integer) - месяц (начиная с 1)
 d: number (integer) - день
 h: nil or number (integer) - час (необязательный параметр, по умолчанию 0)
 min: nil or number (integer) - минута (необязательный параметр, по умолчанию 0)
 s: nil or number (integer) - секунда (необязательный параметр, по умолчанию 0)
 ms: nil or number (integer) - миллисекунда (необязательный параметр, по умолчанию 0)

-- возвращаемые значение:
timeMs: number (integer) - Unix time (время в миллисекундах прошедшее с 1-го января 1970 года)

-- пример:
local ms = common.GetMsFromDateTime( common.GetLocalDateTime() )

Связанные страницы: "CategoryLuaApi" "CategoryCommon"

CategoryCommon
EnumGoalState
EventAddonLoadStateChanged
EventAllodsGoalAdded
EventAllodsGoalChanged
EventAllodsGoalCompleted
EventFullscreenChanged
EventLocaleChanged
EventUserScreenshot
FunctionCommonCreateValuedObject
FunctionCommonCreateValuedText
FunctionCommonEnableUIRender
FunctionCommonExtractWStringFromValuedText
FunctionCommonFormatFloat
FunctionCommonFormatInt
FunctionCommonFormatNumber
FunctionCommonGetAddonInfo
FunctionCommonGetAddonMainForm
FunctionCommonGetAddonName
FunctionCommonGetAllodsGoals
FunctionCommonGetAllodsGoalsOnLoadingScreen
FunctionCommonGetApiType
FunctionCommonGetCredits
FunctionCommonGetCSSList
FunctionCommonGetDateTimeFromMs
FunctionCommonGetEmptyWstring
FunctionCommonGetFatalityPhraseLimits
FunctionCommonGetFirstPaymentBonusInfo
FunctionCommonGetInstanceIdByInteger
FunctionCommonGetIntFromWString
FunctionCommonGetLocalDateTime
FunctionCommonGetLocalDateTimeMs
FunctionCommonGetLocale
FunctionCommonGetLocaleList
FunctionCommonGetLocalization
FunctionCommonGetMsFromDateTime
FunctionCommonGetRandFloat
FunctionCommonGetRandInt
FunctionCommonGetScriptCfgVar
FunctionCommonGetShortString
FunctionCommonGetStateManagedAddons
FunctionCommonGetStateName
FunctionCommonGetTerritoryInfo
FunctionCommonGetTexturePath
FunctionCommonIsCapsLockEnabled
FunctionCommonIsEmptyValuedText
FunctionCommonIsEmptyWstring
FunctionCommonIsEqualStats
FunctionCommonIsFatalityPhraseFiltered
FunctionCommonIsKeyEnabled
FunctionCommonIsOnPayToPlayShard
FunctionCommonIsSoundEnabled
FunctionCommonIsSubstring
FunctionCommonIsSubstringEx
FunctionCommonIsTextFiltered
FunctionCommonIsUIRenderEnabled
FunctionCommonIsValidText
FunctionCommonIsValuedObject
FunctionCommonIsValuedText
FunctionCommonIsWString
FunctionCommonLogError
FunctionCommonLogInfo
FunctionCommonLogWarning
FunctionCommonMakeUserScreenshot
FunctionCommonOnEvent
FunctionCommonOnReaction
FunctionCommonQuitGame
FunctionCommonRegisterEventHandler
FunctionCommonRegisterReactionHandler
FunctionCommonRequestIntegerByInstanceId
FunctionCommonSetCursor
FunctionCommonSetIconFlash
FunctionCommonSetLocale
FunctionCommonSetTextValues
FunctionCommonStateLoadManagedAddon
FunctionCommonStateLoadManagedAddonGroup
FunctionCommonStateUnloadManagedAddon
FunctionCommonStateUnloadManagedAddonGroup
FunctionCommonUnRegisterEvent
FunctionCommonUnRegisterEventHandler
FunctionCommonUnRegisterReactionHandler
FunctionCompareWString
FunctionCompareWStringEx
FunctionEscapeWString
FunctionGetWStringLength
FunctionGlobal
FunctionTruncateWString
GoalId


CategoryLuaApi CategoryFunction CategoryCommon

На главную