docs/Unity.md
This project is still in early development, expect some rough edges. We are working to fully support the full AirLib API and feature set, but some things may be missing. Click here for the list of currently supported APIs.
Install Visual Studio 2019. Make sure to select Desktop Development with C++ and Windows 10 SDK 10.0.18362 (should be selected by default) while installing VS 2019.
Start x64 Native Tools Command Prompt for VS 2019.
Clone the repo: git clone https://github.com/Microsoft/AirSim.git, and go the AirSim directory by cd AirSim.
Run build.cmd from the command line.
cd Unity.build.cmd.Windridge City which you can download from Unity Asset Store. And, of course, you can always create your own environment.sudo apt-get install libboost-all-dev
<span style="color:red">Warning:</span> Unity Editor for Linux is still in Beta. Expect some rough edges.
git clone https://github.com/Microsoft/AirSim.git;
cd AirSim;
./setup.sh;
./build.sh
cd AirSim/Unity
./build.sh
This will generate the necessary shared library and copy it to the UnityDemo Plugins folder.
Projects on left pane, and then click on the Add buttonAirSim\Unity\UnityDemo, and then hit the OK button.Projects->Assets->Scenes. Then, Double-click on SimModeSelector. This will load the SimModeSelector scene into the scene hierarchy pane. DO NOT add CarDemo or DroneDemo scene into the scene hierarchy pane.Settings.json file. (You can read more about Settings.json here)WASD or the Arrow keys or the AirSim client.0, 1, 2, 3 are used to toggle windows of different camera views.Documents\AirSim\(Date of recording) on Windows and ~/Documents/AirSim/(Date of recording) on Linux.To use environments other than UnityDemo, follow the instructions written here
Unity Editor supports compiling projects to Linux systems. After following the steps to build AirSim and Unity on Windows, do the following:
Before being able to run Unity Binaries with the Airsim plugin, be sure have airsim and airsim unity built on your linux machine by following the Linux build steps above.
In order to package your project for linux, the Linux Build Support Unity add-on must be installed.
File -> Build SettingsBuild"{project_name}_Data" to your linux machinecp Unity/linux-build/libAirsimWrapper.so path/to/your/project/{project_name}_Data/Plugins/{os_version}
This will generate the necessary shared library to allow Airsim to communicate with Unity and copy it to the plugins folder of your project binary.
chmod +x "{project_name}.{configuration}"
./{project_name}.{configuration}
hello_car.py or the hello_drone.py script accordingly.