GetClassDerivationLevel(string)

grandMA3 ユーザマニュアル » プラグイン » Lua 関数 - Object-Free API » GetClassDerivationLevel(string) Version 2.2

説明

GetClassDerivationLevel 関数は、クラス名に基づく派生レベル・インデックスを整数で返します。

引数

  • string:
    この文字列は、クラス名でなければなりません。

戻り値

  • integer:
    クラスの派生レベルを表す整数を返します。

Pool クラスのインデックス番号を Command Line History に出力します。

Lua
return function()
    -- Get the index integer for the "Pool" class.
    local classDerivationLevel = GetClassDerivationLevel("Pool")
    -- Create a valid Printf return.
    if classDerivationLevel == nil then
        Printf("The return is nil")
    else
        Printf("The ClassDerivationLevel index for 'Pool' is: %i", classDerivationLevel)
    end
end