# Getting Started

## Install

Get it from [Unity Asset Store](https://assetstore.unity.com/packages/tools/audio/bro-audio-257362), install it from Package Manager

## Creating sound libraries

* **Locate** *<mark style="color:orange;">**Tools > BroAudio > Library Manager**</mark>***&#x20;in the Unity menu bar.**
* **Drag and drop the required AudioClip.**

<div align="center" data-full-width="false"><figure><img src="https://886210201-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FfI79StJ3o7OKZxf9vHhb%2Fuploads%2FIE7ysBjvZkHApbQs39cK%2FDragNDrop.gif?alt=media&#x26;token=27c80f8b-8e0c-4333-9003-ae1ee0a68b0a" alt="" width="563"><figcaption><p>If multiple clips are dropped, a confirmation window will appear, asking how you would like to structure them.</p></figcaption></figure></div>

* **Edit the parameters**\
  edit the clip's volume, playback position... etc.
* **Name the asset and entities and choose an** [**AudioType**](https://man572142s-organization.gitbook.io/broaudio/reference/api-documentation/enums/broaudiotype)\
  You could also skip this step. Just remember to set it before you need them in your scene.

## Implementation

You can implement the sound you've created in Library Manager with or without coding.

### Without Code&#x20;

* **Add** <img src="https://886210201-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FfI79StJ3o7OKZxf9vHhb%2Fuploads%2Ftl67dqZjUj5nZH0CG5dk%2FBroAudio_Logo_900x900.png?alt=media&#x26;token=0a17611a-aada-4eee-853e-4e00379469c8" alt="" data-size="line">**SoundSource component to a game object**
* **Select the required sound via the dropdown menu**

<figure><img src="https://886210201-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FfI79StJ3o7OKZxf9vHhb%2Fuploads%2FL6ysT8NV3kDCNG8BoB9A%2FUnity_VVf8IWAV8o.gif?alt=media&#x26;token=94af1bae-086b-453c-8732-d2255deb6577" alt="" width="401"><figcaption></figcaption></figure>

* **Choose the triggering strategy**\
  Enables "Play On Start" if you want to play it when the game object is activated at runtime. Or using [UnityEvent](https://docs.unity3d.com/2022.3/Documentation/Manual/UnityEvents.html) to trigger the Play() function like the Button's OnClick as below.&#x20;

<figure><img src="https://886210201-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FfI79StJ3o7OKZxf9vHhb%2Fuploads%2FvJKy6u4NNZWd1fYMDHIs%2FTriggerByUnityEvent.png?alt=media&#x26;token=a09aa014-2e3e-4f8b-b5ca-617dc7b05e51" alt="" width="401"><figcaption></figcaption></figure>

### With Code

* **Declare a** [**SoundID**](https://man572142s-organization.gitbook.io/broaudio/core-features/library-manager#soundid) **and implement `BroAudio.Play()` to play it**

<figure><img src="https://886210201-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FfI79StJ3o7OKZxf9vHhb%2Fuploads%2Fq9iuTTM70cD2urGbBuDW%2FBasicAPI2.png?alt=media&#x26;token=30d39bd0-4390-4ca8-ae13-d1ae64ea4a38" alt="" width="563"><figcaption></figcaption></figure>

* **Select the required sound via the dropdown menu in the Inspector**\
  The same way as using [SoundSource](#implementation-no-code).

## Hit the play button and enjoy it!

That's all you need to start using BroAudio. Of course, there is more than just this. Check out the rest of the documentation to fully unlock all the features of BroAudio.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://man572142s-organization.gitbook.io/broaudio/overview/getting-started.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
