[ToggleProperty]

Displays a field with a toggle that controls its visibility or enabled state.

Parameters

Parameter Name
Arguments
Description

boolValue

string

Name of the boolean field that controls the toggle state.

Hide

bool

Hide property, otherwise property will be disabled.

Examples

using UnityEngine;
using RenownedGames.Apex;

public class TogglePropertyExample : MonoBehaviour
{
    public bool showSettings;

    [ToggleProperty("showSettings")]
    public float settingValue;

    public bool enableFeature;

    [ToggleProperty("enableFeature", Hide = false)]
    public string featureName;
}

Last updated