Class ScenePlacementModule | MARS | 1.0.1
docs.unity3d.com
    Show / Hide Table of Contents

    Class ScenePlacementModule

    Module that handles placing objects in the scene onto interaction targets when dragging objects from the project window and translating objects while holding Shift

    Inheritance
    Object
    ScenePlacementModule
    Namespace: Unity.MARS
    Syntax
    public class ScenePlacementModule : IModuleDependency<SceneViewInteractionModule>, IModuleDependency<SimulationSceneModule>, IModule

    Properties

    isDragging

    Declaration
    public bool isDragging { get; }
    Property Value
    Type Description
    Boolean

    orientAxis

    Axis for the up direction of an object being oriented to a surface

    Declaration
    public AxisEnum orientAxis { get; set; }
    Property Value
    Type Description
    AxisEnum

    orientToSurface

    If enabled, objects being placed in the editor should orient to the surface

    Declaration
    public bool orientToSurface { get; set; }
    Property Value
    Type Description
    Boolean

    PlacementOverrides

    Declaration
    public ScenePlacementModule.PlacementOverrideData PlacementOverrides { get; }
    Property Value
    Type Description
    ScenePlacementModule.PlacementOverrideData

    snapToPivot

    If enabled, objects being placed in the editor should snap to the pivot of the target

    Declaration
    public bool snapToPivot { get; set; }
    Property Value
    Type Description
    Boolean

    Methods

    ConnectDependency(SceneViewInteractionModule)

    Declaration
    public void ConnectDependency(SceneViewInteractionModule dependency)
    Parameters
    Type Name Description
    SceneViewInteractionModule dependency
    Implements
    IModuleDependency<T>.ConnectDependency(T)

    ConnectDependency(SimulationSceneModule)

    Declaration
    public void ConnectDependency(SimulationSceneModule dependency)
    Parameters
    Type Name Description
    SimulationSceneModule dependency
    Implements
    IModuleDependency<T>.ConnectDependency(T)

    LoadModule()

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

    UnloadModule()

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

    Events

    ObjectDropped

    Action when a gameobject is dropped onto another gameobject and attached to it.

    Declaration
    public event Action<GameObject, GameObject> ObjectDropped
    Event Type
    Type Description
    Action<GameObject, GameObject>
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023