# \[Windows]\[Basic] Canary + Uniform Server + MyAAC

{% hint style="info" %}

* **If you not compiled Canary, start following this tutorial at step 1.**
* **If you already compiled Canary, start following this tutorial at step 2.**
  {% endhint %}

## **1 - Download Canary:**&#x20;

* [Download](https://github.com/opentibiabr/canary)
* Extract Canary server in a folder of your preference.

### **Compiled Canary:**

* [Download](https://docs.opentibiabr.com/opentibiabr/projects/canary/about#nightly-packages)

## **2 - Download Uniform Server:**

* [Download](https://sourceforge.net/projects/miniserver/files/Uniform%20Server%20ZeroXV/15_0_1_ZeroXV/15_0_1_ZeroXV.exe/download)

## **3 - Installation and Configuration:**

<details>

<summary>Uniform Server</summary>

* Install Uniform Server (15\_0\_1\_ZeroXV) on the C:\ drive.
* **Example:**
* ![](https://content.gitbook.com/content/zV9t92sKcMkphxwdvwZs/blobs/APZjhxF9JjvqTxGmUjQo/7zip.png)
* On unit C:\ after installation, the folder name is UniServerZ.
* When you open Uniform Server, a window will open asking for the MySQL root password:
* ![](https://content.gitbook.com/content/zV9t92sKcMkphxwdvwZs/blobs/EdMTtclzidlUL1M9GWhj/mysql.png)
* The default password in this case is root.
* Go to **C:\UniServerZ** and open the **UniController.exe**.
* ![](https://1381914140-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FzV9t92sKcMkphxwdvwZs%2Fuploads%2FbXuIqS5IVg0J5p3EQziu%2Funiserver.png?alt=media\&token=4d6d764a-f095-43d5-ab36-51cce383e063)
* **Change thread stack:**
* Navigate to **MySQL -> Edit Config file my.ini** and change:
* thread\_stack = 256K
* Save the file.
* **Edit Configuration file (php.ini):**
* Navigate to **PHP -> Edited selected configuration file** and change:
* upload\_max\_filesize=100M
* post\_max\_size=100M
* Save the file.
* **Enable PHP Extensions:**
* Navigate to **PHP -> Edit Basic and Modules -> PHP Modules Enable/Disable** and enable:
* bz2, curl, mbstring, zip;
* **MySQL root password:**
* If you changed MySQL root password, you should change the authentication plugin using the MySQL Console with the command:
* ```sql
  ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'yourpassword';
  ```
* **To start Uniform Server:**
* Click in the **Start Apache** butto&#x6E;**;**
* Click in the **Start MySQL** butto&#x6E;**.**
* ![](https://1381914140-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FzV9t92sKcMkphxwdvwZs%2Fuploads%2FC1ejeV9eoq5Kazf6kIbz%2Funiform_server_apache_mysql.png?alt=media\&token=8c6322e9-4044-4914-b299-0ded5be86614)

</details>

## **4 - Database:**

* In Uniform Server, click the **phpMyAdmin** button and will open in the browser the web application to manage database.
* On the left side click +New and create a database (e.g. canary)
* Import the schema file.sql which is in the Canary folder.

## **5** - Config.lua:

<details>

<summary>For data-canary</summary>

```lua
-- Core settings
-- Note: If you want to use datapack folder canary (custom), put only "data-canary"
-- If you want to use the global datapack folder, put "data-otservbr-global"
-- If "useAnyDatapackFolder" is set to true then you can choose any datapack folder for your server
useAnyDatapackFolder = false
dataPackDirectory = "data-canary"
-- Don't change this unless you know what you're doing
coreDirectory = "data"

-- Map
-- NOTE: set mapName WITHOUT .otbm at the end
-- NOTE: If toggleDownloadMap if false, then the mapDownloadUrl will not be used
-- NOTE: If a map with the name already exists in the world folder, the map will not be downloaded even if the toggleDownloadMap is true
toggleDownloadMap = false
mapName = "canary"

-- Custom Map
-- NOTE: toggleMapCustom set to true will load all maps in custom map folder
toggleMapCustom = false

-- Connection Config
ip = "127.0.0.1"
serverName = "Canary"

-- MySQL
mysqlHost = "127.0.0.1"
mysqlUser = "root"                      
mysqlPass = "root"                       
mysqlDatabase = "canary"        
mysqlPort = 3306
mysqlSock = ""
passwordType = "sha1"
```

</details>

<details>

<summary>For data-otservbr-global</summary>

```lua
-- Core settings
-- Note: If you want to use datapack folder canary (custom), put only "data-canary"
-- If you want to use the global datapack folder, put "data-otservbr-global"
-- If "useAnyDatapackFolder" is set to true then you can choose any datapack folder for your server
useAnyDatapackFolder = false
dataPackDirectory = "data-otservbr-global"
-- Don't change this unless you know what you're doing
coreDirectory = "data"

-- Map
-- NOTE: set mapName WITHOUT .otbm at the end
-- NOTE: If toggleDownloadMap if false, then the mapDownloadUrl will not be used
-- NOTE: If a map with the name already exists in the world folder, the map will not be downloaded even if the toggleDownloadMap is true
toggleDownloadMap = true
mapName = "otservbr"

-- Custom Map
-- NOTE: toggleMapCustom set to true will load all maps in custom map folder
toggleMapCustom = true

-- Connection Config
ip = "127.0.0.1"
serverName = "OTServBR-Global"

-- MySQL
mysqlHost = "127.0.0.1"
mysqlUser = "root"                      
mysqlPass = "root"                       
mysqlDatabase = "otservbr-global"        
mysqlPort = 3306
mysqlSock = ""
passwordType = "sha1"
```

</details>

## **6 - MyAAC:**

### **6.1 - Download:**

* Download the **myaac-1.x.zip** file.
* [Download](https://github.com/slawkens/myaac/releases/latest)

### 6.2 - Installation:

<details>

<summary>MyAAC</summary>

* Go to **C:\UniServerZ\www** and delete all files inside.
* Unzip downloaded MyAAC files and paste the content into **C:\UniServerZ\\[www](http://www).**
* At the end it looks like this:
* ![](https://1381914140-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FzV9t92sKcMkphxwdvwZs%2Fuploads%2FuSv4J8U5dFpwsD1RhKli%2Fmyaac_folder.png?alt=media\&token=38683486-436a-46ba-84ab-4f62e7e865a6)
* Visit **<http://127.0.0.1>** to load MyAAC.
* Follow the installation steps to install MyAAC.

</details>

## **7 - Starting and Connecting to the Server:**

### **7.1 - Starting the Server:**

* Double click canary.exe, it will start the server.

### 7.2 - Connecting to the Server:

* To connect to the server according to the indicated version, you can use:
* [**Normal Client**](https://docs.opentibiabr.com/opentibiabr/downloads/clients/client-13)
* [**OTClient Redemption**](https://docs.opentibiabr.com/opentibiabr/projects/otclient-redemption/about#how-to-connect-on-canary-with-otclient-redemption)

## **8 - Credits:**

* **OpenTibiaBR (**[**https://github.com/opentibiabr/canary**](https://github.com/opentibiabr/canary)**)**
* **Slawkens (**[**https://github.com/slawkens/myaac**](https://github.com/slawkens/myaac)**)**
* **Tutorial:**
* **Majesty**
