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

На главную

## transport.GetDevices( transportId )

Возвращает список идентификаторов используемых устройств транспортного средства. Если транспорт не найден, то возвращает пустую таблицу.

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

    -- объявление:
    function GetDevices( transportId )

    -- параметры:
    transportId: ObjectId (not nil) -- идентификатор транспортного средства

    -- возвращаемые значения -
    table of ObjectId - Если транспортное средство найдено, то возвращается таблица идентификаторов используемых устройств

    -- пример:
    local transportId = unit.GetTransport( avatar.GetId() )
    if transportId then
      local devices = transport.GetDevices( transportId )
      for i, deviceId in devices do
        local name = device.GetName( deviceId ) )
      end
    end

#### Search: "CategoryLuaApi" "CategoryTransport"

EnumCriticalMalfunctionType
EnumShipSide
EventAstrolabeInfoChanged
EventAvatarBindedTransportChanged
EventAvatarTransportChanged
EventReactorCountDown
EventReactorCountDownCancelled
EventShipDamageReceived
EventTransportAccelerationTargetChanged
EventTransportAngularVelocityChanged
EventTransportCriticalMalfunction
EventTransportDespawned
EventTransportDevicesChanged
EventTransportDirectionChanged
EventTransportEnergyChanged
EventTransportHorizontalVelocityChanged
EventTransportInsightChanged
EventTransportObservingFinished
EventTransportObservingStarted
EventTransportPosChanged
EventTransportsChanged
EventTransportShieldChanged
EventTransportShipInfoChanged
EventTransportSpawned
EventTransportVerticalVelocityChanged
FunctionAstralAstrolabeJump
FunctionAstralGetAstrolabeDeniedPlayers
FunctionAvatarGetBindedTransport
FunctionAvatarGetObservedAstralUnit
FunctionAvatarGetObservedTransport
FunctionAvatarGetTransportList
FunctionDeviceGetNavigatorTargetChests
FunctionDeviceNavigatorGetTarget
FunctionDeviceNavigatorGetZoomedObject
FunctionDeviceNavigatorSetTarget
FunctionTransportCanDrawInterface
FunctionTransportGetAcceleratorNominalMass
FunctionTransportGetDevices
FunctionTransportGetDirection
FunctionTransportGetEnergy
FunctionTransportGetHealthMaximum
FunctionTransportGetInsight
FunctionTransportGetMass
FunctionTransportGetPosition
FunctionTransportGetShieldStrength
FunctionTransportGetShipInfo
FunctionTransportGetVelocities
FunctionTransportIsEnemy
FunctionTransportIsFriend
FunctionUnitGetTransport

CategoryLuaApi CategoryFunction CategoryDevice CategoryTransport

На главную