Set(handle, string, string[, integer])

grandMA3 ユーザマニュアル » プラグイン » Lua 関数 - Object API » Set(handle, string, string[, integer]) Version 2.2

説明

Set 関数は、オブジェクトの指定したプロパティに値を設定します(例: オブジェクト名など)。

引数

  • handle:
    light_userdata 型のハンドルです。オブジェクトでコロン記法を用いる場合は省略できます。
  • string:
    オブジェクトの有効なプロパティ名を含む文字列です。
  • string:
    プロパティに設定したい値を含む文字列です。
  • integer (オプション):

戻り値

この関数は何も返しません。

この例では、選択したシーケンスの "Tracking" プロパティを "No" に変更します。

Lua
return function()
    -- SelectedSequence() creates a handle to the selected sequence.
    local selectedSequence = SelectedSequence()
    -- Set a variable with the property name.
    local propertyName = "Tracking"
    -- Set the property.
    selectedSequence:Set(propertyName, "No")
end