Miscellaneous

setfflag

Sets a Roblox fast flag by exact name.

構文

setfflag(name: string, value: any): boolean

引数

名前説明
namestringExact fast flag name to set.
valueanyValue to write. Accepted types depend on the detected flag type.

戻り値

名前説明
updatedbooleantrue when a supported flag value was written, otherwise false.

説明

Sets a Roblox fast flag by exact name. Accepted value types depend on the detected flag type. The function returns true after a supported write and false when the flag is missing, unsupported, or the value is not accepted.

2 個のパラメータで呼び出します: name, value。引数表では必須値と動作を調整する値を確認できます。

updated (boolean) を返します。戻り値表を使って成功値、nil 結果、回復可能なエラーを分けて扱ってください。

Write a fast flag only after checking the flag type that Real detected for the exact name.

local flagName = "SomeFFlagName"
local flagType = getfflagtype(flagName)

if flagType == "bool" then
    print(setfflag(flagName, true))
elseif flagType == "int" then
    print(setfflag(flagName, 60))
elseif flagType == "string" then
    print(setfflag(flagName, "Enabled"))
else
    print(false)
end