# SAudioReactiveTransform

**Membres** 12

|           |                             |                                                                                        |
| --------- | --------------------------- | -------------------------------------------------------------------------------------- |
| Propriété | [Enabled](#enabled)         | Whether the Audio Reactive Transform component is enabled or not.                      |
| Propriété | [Target](#target)           | The target GameObject which will be affected by the Audio Reactive Transform.          |
| Propriété | [Position](#position)       | Whether or not the target's position will be affected by the Audio Reactive Transform. |
| Propriété | [MinPosition](#minposition) | Returns MinPosition value of the Audio Reactive Transform.                             |
| Propriété | [MaxPosition](#maxposition) | Returns MaxPosition value of the Audio Reactive Transform.                             |
| Propriété | [Rotation](#rotation)       | Whether or not the target's rotation will be affected by the Audio Reactive Transform. |
| Propriété | [MinRotation](#minrotation) | Returns MinRotation value of the Audio Reactive Transform.                             |
| Propriété | [MaxRotation](#maxrotation) | Returns MaxRotation value of the Audio Reactive Transform.                             |
| Propriété | [Scale](#scale)             | Whether or not the target's scale will be affected by the Audio Reactive Transform.    |
| Propriété | [MinScale](#minscale)       | Returns MinScale value of the Audio Reactive Transform.                                |
| Propriété | [MaxScale](#maxscale)       | Returns MaxScale value of the Audio Reactive Transform.                                |
| Propriété | [GameObject](#gameobject)   | Returns a reference to the GameObject of this component.                               |

## Propriétés

### Enabled

bool Enabled {get; set; }

Whether the Audio Reactive Transform component is enabled or not.

Exemple

**Lua**

```lua
Space.Host.ExecutingObject.AudioReactiveTransform.Enabled= false

```

**Lua**

```lua
--clicking this object will Enable/Disable it's Audio Reactive Transform component
thisGameObject = Space.Host.ExecutingObject
component = thisGameObject.AudioReactiveTransform


OnClick = function()
component.Enabled =  not component.Enabled
end


thisGameObject.AddClickable()
thisGameObject.Clickable.OnClick(OnClick)

```

### Target

[SGameObject](/docs/fr/scripting/client-scripting-api-reference/types/sgameobject.md) Target {get; set; }

The target GameObject which will be affected by the Audio Reactive Transform.

Exemple

**Lua**

```lua
target = Space.Host.ExecutingObject.AudioReactiveTransform.Target

```

**Lua**

```lua
--clicking this object will toggle between two different Audio Reactive Transform targets
thisObject = Space.Host.ExecutingObject
target1 = Space.Host.GetReference("theTarget1") --add this reference to Scripting Runtime component
target2 = Space.Host.GetReference("theTarget2") --add this reference to Scripting Runtime component

function OnClickFunction()
  if thisObject.AudioReactiveTransform.Target == target1 then
    thisObject.AudioReactiveTransform.Target = target2
  else
    thisObject.AudioReactiveTransform.Target = target1
  end
end

thisObject.AddClickable()
thisObject.Clickable.OnClick(OnClickFunction)

```

### Position

bool Position {get; set; }

Whether or not the target's position will be affected by the Audio Reactive Transform.

Exemple

**Lua**

```lua
Space.Host.ExecutingObject.AudioReactiveTransform.Position = true

```

**Lua**

```lua
--clicking this object will toggle it's Audio Reactive Transform Position property 
thisObject = Space.Host.ExecutingObject

function OnClickFunction()
   thisObject.AudioReactiveTransform.Position = not thisObject.AudioReactiveTransform.Position
end

thisObject.AddClickable()
thisObject.Clickable.OnClick(OnClickFunction)

```

### MinPosition

[SVector](/docs/fr/scripting/client-scripting-api-reference/types/svector.md) MinPosition {get; set; }

Returns MinPosition value of the Audio Reactive Transform.

Exemple

**Lua**

```lua
Space.Host.ExecutingObject.AudioReactiveTransform.MinPosition = Vector.New(0,1,0)

```

### MaxPosition

[SVector](/docs/fr/scripting/client-scripting-api-reference/types/svector.md) MaxPosition {get; set; }

Returns MaxPosition value of the Audio Reactive Transform.

Exemple

**Lua**

```lua
Space.Host.ExecutingObject.AudioReactiveTransform.MaxPosition = Vector.New(1,2,1)

```

### Rotation

bool Rotation {get; set; }

Whether or not the target's rotation will be affected by the Audio Reactive Transform.

Exemple

**Lua**

```lua
Space.Host.ExecutingObject.AudioReactiveTransform.Rotation= true

```

**Lua**

```lua
--clicking this object will toggle it's Audio Reactive Transform Rotation property 
thisObject = Space.Host.ExecutingObject

function OnClickFunction()
   thisObject.AudioReactiveTransform.Rotation= not thisObject.AudioReactiveTransform.Rotation
end

thisObject.AddClickable()
thisObject.Clickable.OnClick(OnClickFunction)

```

### MinRotation

[SVector](/docs/fr/scripting/client-scripting-api-reference/types/svector.md) MinRotation {get; set; }

Returns MinRotation value of the Audio Reactive Transform.

Exemple

**Lua**

```lua
Space.Host.ExecutingObject.AudioReactiveTransform.MinRotation = Vector.New(0,30,0)

```

### MaxRotation

[SVector](/docs/fr/scripting/client-scripting-api-reference/types/svector.md) MaxRotation {get; set; }

Returns MaxRotation value of the Audio Reactive Transform.

Exemple

**Lua**

```lua
Space.Host.ExecutingObject.AudioReactiveTransform.MinRotation = Vector.New(0,60,0)

```

### Scale

bool Scale {get; set; }

Whether or not the target's scale will be affected by the Audio Reactive Transform.

Exemple

**Lua**

```lua
Space.Host.ExecutingObject.AudioReactiveTransform.Scale= true

```

**Lua**

```lua
--clicking this object will toggle it's Audio Reactive Transform Scale property 
thisObject = Space.Host.ExecutingObject

function OnClickFunction()
   thisObject.AudioReactiveTransform.Scale= not thisObject.AudioReactiveTransform.Scale
end

thisObject.AddClickable()
thisObject.Clickable.OnClick(OnClickFunction)

```

### MinScale

[SVector](/docs/fr/scripting/client-scripting-api-reference/types/svector.md) MinScale {get; set; }

Returns MinScale value of the Audio Reactive Transform.

Exemple

**Lua**

```lua
Space.Host.ExecutingObject.AudioReactiveTransform.MinScale = Vector.New(1,1,1)

```

### MaxScale

[SVector](/docs/fr/scripting/client-scripting-api-reference/types/svector.md) MaxScale {get; set; }

Returns MaxScale value of the Audio Reactive Transform.

Exemple

**Lua**

```lua
Space.Host.ExecutingObject.AudioReactiveTransform.MaxScale = Vector.New(2,2,2)

```

### GameObject

[SGameObject](/docs/fr/scripting/client-scripting-api-reference/types/sgameobject.md) GameObject {get; }

Returns a reference to the GameObject of this component.

Exemple

**Lua**

```lua
theGameObject = Space.Host.ExecutingObject.AudioReactiveTransform.GameObject

```
