docs.unity3d.com
    显示 / 隐藏目录

    Class MARSWorldScaleModule

    Manages world scale adjustment for each scene

    Inheritance
    Object
    ScriptableSettingsBase
    ScriptableSettingsBase<MARSWorldScaleModule>
    EditorScriptableSettings<MARSWorldScaleModule>
    MARSWorldScaleModule
    Inherited Members
    EditorScriptableSettings<MARSWorldScaleModule>.instance
    ScriptableSettingsBase<MARSWorldScaleModule>.k_HasCustomPath
    ScriptableSettingsBase<MARSWorldScaleModule>.s_Instance
    ScriptableSettingsBase<MARSWorldScaleModule>.Save(String)
    ScriptableSettingsBase<MARSWorldScaleModule>.GetFilePath()
    ScriptableSettingsBase.k_PathExceptionMessage
    ScriptableSettingsBase.GetInstanceByType(Type)
    ScriptableSettingsBase.OnLoaded()
    Namespace: Unity.MARS
    Syntax
    public class MARSWorldScaleModule : EditorScriptableSettings<MARSWorldScaleModule>, IModule

    Properties

    largeScaleIcon

    Declaration
    public MARSWorldScaleModule.ScaleVisual largeScaleIcon { get; }
    Property Value
    Type Description
    MARSWorldScaleModule.ScaleVisual

    maxScale

    Declaration
    public float maxScale { get; }
    Property Value
    Type Description
    Single

    maxScaleExponent

    Declaration
    public int maxScaleExponent { get; }
    Property Value
    Type Description
    Int32

    minScale

    Declaration
    public float minScale { get; }
    Property Value
    Type Description
    Single

    minScaleExponent

    Declaration
    public int minScaleExponent { get; }
    Property Value
    Type Description
    Int32

    scaleOneIcon

    Declaration
    public MARSWorldScaleModule.ScaleVisual scaleOneIcon { get; }
    Property Value
    Type Description
    MARSWorldScaleModule.ScaleVisual

    smallScaleIcon

    Declaration
    public MARSWorldScaleModule.ScaleVisual smallScaleIcon { get; }
    Property Value
    Type Description
    MARSWorldScaleModule.ScaleVisual

    visualsZeroIndex

    Declaration
    public int visualsZeroIndex { get; }
    Property Value
    Type Description
    Int32

    Methods

    AdjustWorldScale(Single)

    Declaration
    public float AdjustWorldScale(float scale)
    Parameters
    Type Name Description
    Single scale
    Returns
    Type Description
    Single

    ApplyWorldScaleToEnvironment()

    Scales synthetic environment components with scalar values not effect by the lossy scale of an object.

    Declaration
    public void ApplyWorldScaleToEnvironment()

    ClearEnvironmentRangeScaledComponents()

    Clears the list of Components that have scalar values that need world scale applied to them

    Declaration
    public void ClearEnvironmentRangeScaledComponents()

    GetEnvironmentRangeScaledComponents(GameObject)

    Gets Components that have values that need world scale applied to them.

    Declaration
    public void GetEnvironmentRangeScaledComponents(GameObject go)
    Parameters
    Type Name Description
    GameObject go

    game object that we are getting components on

    GetWorldScale()

    Declaration
    public static float GetWorldScale()
    Returns
    Type Description
    Single

    LoadModule()

    Declaration
    public void LoadModule()
    Implements
    IModule.LoadModule()

    ScaleChildren(Transform)

    Scale the child objects local position and scale by the current world scale.

    Declaration
    public static void ScaleChildren(Transform parent)
    Parameters
    Type Name Description
    Transform parent

    Parent transform of the children to scale

    UnloadModule()

    Declaration
    public void UnloadModule()
    Implements
    IModule.UnloadModule()

    UpdateScaleReference()

    Declaration
    public void UpdateScaleReference()
    返回到顶部
    Copyright © 2023 Unity Technologies — 商标和使用条款
    • 法律条款
    • 隐私政策
    • Cookie
    • 不要出售或分享我的个人信息
    • Your Privacy Choices (Cookie Settings)