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

На главную

## mount.GetUnitMountHealth( unitId )

Возвращает информацию о здоровье используемого ездового животного игрока.

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

    -- объявление:
    function GetUnitMountHealth( unitId )

    -- параметры:
    unitId: ObjectId (not nil) -- идентификатор юнита

    -- возвращаемые значения -
    table or nil - если есть маунт, то таблица с полями:
      health: number (integer) - здоровье
      healthLimit: number (integer) - максимум здоровье

    -- пример:
    local mountInfo = mount.GetUnitMountHealth( unitId )
    if mountInfo then
      local healthLevel = mountInfo.health / mountInfo.healthLimit
    end

#### Search: "CategoryLuaApi" "CategoryMount"

EventActiveMountChanged
EventActiveMountSkinChanged
EventActiveMountTimeLeftChanged
EventStableFoodCountChanged
EventStableMountAdded
EventStableMountChanged
EventStableMountRemoved
EventStableMountsChanged
EventStableMountSkinsChanged
EventStableSlotsCountChanged
EventUnitMountHealthChanged
FunctionAvatarBindMountMetamorphToActionPanel
FunctionAvatarBindMountSkinToActionPanel
FunctionAvatarBindMountToActionPanel
FunctionMissionSetMountScene
FunctionMountDismount
FunctionMountFeed
FunctionMountGetActive
FunctionMountGetActiveSatiation
FunctionMountGetActiveSkin
FunctionMountGetActiveTimeLeftMs
FunctionMountGetInfo
FunctionMountGetMetamorph
FunctionMountGetMetamorphBaseInfo
FunctionMountGetMetamorphName
FunctionMountGetMounts
FunctionMountGetMountSkins
FunctionMountGetSkinInfo
FunctionMountGetStableInfo
FunctionMountGetUnitMountHealth
FunctionMountGetValuedObject
FunctionMountHasSwitchCost
FunctionMountIsMountExist
FunctionMountIsStableExist
FunctionMountRide
FunctionMountSetMetamorphSkin
FunctionMountSetSkin
FunctionSocialGetBackMount
FunctionSocialGiveBackMount
FunctionSocialLendMount

CategoryLuaApi CategoryFunction CategoryUnit CategoryMount

На главную