docs.unity3d.com
    Show / Hide Table of Contents

    Class ProxyRegionForcePlane2D

    Applies a planar region attraction force to the proxy at its origin.

    Inheritance
    Object
    ProxyRegionForcePlane2D
    Namespace: Unity.MARS.Forces
    Syntax
    public class ProxyRegionForcePlane2D : MonoBehaviour, IProxyRegionForceSource, IMatchAcquireHandler, IMatchUpdateHandler, IMatchLossHandler, IAction, ISimulatable, IUsesMARSTrackableData<MRPlane>

    Properties

    KeepMatchPlane

    When enabled within a plane proxy, only is attracted to the matched plane.

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

    planeAlignment

    Alignment the plane should be attracted towards

    Declaration
    public MarsPlaneAlignment planeAlignment { get; set; }
    Property Value
    Type Description
    MarsPlaneAlignment

    planeSize

    Size on the 2d plane in meters

    Declaration
    public Vector2 planeSize { get; set; }
    Property Value
    Type Description
    Vector2

    Methods

    OnMatchAcquire(QueryResult)

    Called when a query match has been found

    Declaration
    public void OnMatchAcquire(QueryResult queryResult)
    Parameters
    Type Name Description
    QueryResult queryResult

    Data associated with this event

    Implements
    IMatchAcquireHandler.OnMatchAcquire(QueryResult)

    OnMatchLoss(QueryResult)

    Called when a query match has been lost

    Declaration
    public void OnMatchLoss(QueryResult queryResult)
    Parameters
    Type Name Description
    QueryResult queryResult

    Data associated with this event

    Implements
    IMatchLossHandler.OnMatchLoss(QueryResult)

    OnMatchUpdate(QueryResult)

    Called when a query match's data has updated

    Declaration
    public void OnMatchUpdate(QueryResult queryResult)
    Parameters
    Type Name Description
    QueryResult queryResult

    Data associated with this event

    Implements
    IMatchUpdateHandler.OnMatchUpdate(QueryResult)

    UpdateFromSources()

    Declaration
    public void UpdateFromSources()

    UpdateRegionDefinitionWithin(ProxyForces)

    Declaration
    public void UpdateRegionDefinitionWithin(ProxyForces proxyForces)
    Parameters
    Type Name Description
    ProxyForces proxyForces
    Back to top
    Terms of use
    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