Class CreateProxyFromData
Creates MARS proxies with conditions based on trait data. Proxies can be created immediately with defaults or opens a window for choosing the conditions and name of the created object.
Inherited Members
Namespace: Unity.MARS.Authoring
Syntax
public class CreateProxyFromData : CreateFromDataBase
Properties
CreatedGameObject
The result game object that has been created
Declaration
public GameObject CreatedGameObject { get; }
Property Value
Type | Description |
---|---|
GameObject |
EditMode
Whether this create data is editing an existing proxy. If true, the proxy will be restored to its prior state when the create is cancelled rather than being destroyed.
Declaration
public bool EditMode { get; }
Property Value
Type | Description |
---|---|
Boolean |
Methods
OnObjectDropped(GameObject, GameObject)
Creates a new proxy with the provided content object as the child and a target proxy gameObject. The trait data of the target proxy's current match will be used to create the conditions on the new proxy
Declaration
public void OnObjectDropped(GameObject droppedObject, GameObject target)
Parameters
Type | Name | Description |
---|---|---|
GameObject | droppedObject | The content that will be attached to the new proxy. |
GameObject | target | The target gameobject that has a matched proxy component. |