-
Notifications
You must be signed in to change notification settings - Fork 5
Setup
You need Unity version that is stated in Readme.md on our GitHub landing page and Visual Studio Community Edition 2019 (Edition 2017 may work, too). We will generally use the latest minor version of Unity LTS. The exact minor version required may depend upon the branch.
To be able to download Unity, you may need to create a Unity account as a student or for personal use.
You can install the required tools with the Windows package manager Chocolatey:
choco install unity --yes
choco install unity-hub --yes
choco install visualstudio2019community --yes
If you have a professional license, you may want to replace visualstudio2019community
with visualstudio2019professional
. The installation of Visual Studio may take quite some time. Be patient.
After installing Visual Studio, run Visual Studio Installer
and press Modify
. Select the package Game development with Unity
and apply the changes with Modify
. Run Visual Studio by pressing the Launch
button at the main menu of Visual Studio Installer
. Log in with your user credentials (your Microsoft account). If necessary, create a new account.
If you are using Visual Studio as an editor, it is highly recommended to install the RemoveTrailingWhitespaces extension, which removes all trailing whitespace upon saving a file.
Run Unity Hub
and log in with your user credentials. If necessary, create a new account. Wait a few seconds until your Unity license was recognized or acquire a new one. Install the latest stable version of the Unity SDK. You'll find your installations at Installs
. Deselect the module Microsoft Visual Studio Community 2019
if Visual Studio is already installed (e.g. with Chocolatey as described above).
Clone the repository:
git clone https://github.com/uni-bremen-agst/SEE
Add SEE to your projects (Unity Hub: Projects
=> Add
). Close Unity Hub
and run Unity
(which again starts Unity Hub
). Open the previously added project and wait until Unity finished its setup.
In order to connect Unity with your Visual Studio installation, go to Edit
=> Preferences
=> External Tools
and select Visual Studio 2019 (Community)
at External Script Editor
. Test your configuration by opening a .cs
file.
It's also recommended to run the generateHook.bat
script in the root folder (simply double-click it).
This will create a pre-commit hook which will warn you in case you try to commit any drawn code cities by mistake.
Building SEE was only tested on Kubuntu 22.04 (Ubuntu should be fine also).
This is largely similar to the Required Tools on Windows, with the three exceptions that:
The following tools are required also:
- ffmpeg codec This can be done by running
apt install ubuntu-restricted-extras
- libssl-1.0 Can be installed with:
add-apt-repository ppa:rael-gc/rvm
apt-get update
apt install libssl1.0-dev
- libvpx (technically optional, but can cause errors if missing)
apt install libvpx
- Unity Hub must be installed as described in this guide
- The "Linux Build Support" module should be selected when installing Unity 2019.4.X LTS from Unity Hub.
- Because Visual Studio Community Edition is not available, a different IDE should be used. JetBrains Rider is a usable alternative with many practical features (e.g. highlighting of performance critical sections) and compatability to Visual Studio projects, but it's only free for students and faculty. Another option would be to use Visual Studio Code, an open-source IDE which is probably closest to Visual Studio Community Edition, though it hasn't been tested for this guide.
When using Rider you might need to install DotNet-Code and Mono
apt install dotnet-sdk-6.0
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
sudo echo "deb https://download.mono-project.com/repo/ubuntu stable-focal main" | sudo tee /etc/apt/sources.list.d/mono-official-stable.list
sudo apt update
sudo apt install mono-devel
-
Install the correct Unity version as described in Required Tools. Note the path where Unity is installed by clicking on "Show in File Browser".
-
Now it should already be possible to open and build the SEE project in Unity. If the menu items appear too small, see HiDPI scaling issues.
-
To now generate the C# project files, run the generateCSProj.sh script while you'in the SEE root directory (This can take quite a bit of time). If Unity is not in the
PATH
(by default, it isn't), the script must be run with the environment variableUNITY_PATH
set to its location:
UNITY_PATH=<unity> ./generateCSProj.sh
Where <unity>
is the path to the Unity executable, which can be found in the Unity Hub.
-
It's also recommended to run the
generateHook.sh
script in the root folder. This will create a pre-commit hook which will warn you in case you try to commit any drawn code cities by mistake. -
Finally, Rider, VSCode or a similar IDE should be installed. This IDE should then be registered within the Unity editor at "Edit => Preferences => External Tools => External Script Editor".
In case a 4K screen (or similar) is used, menu elements may be too tiny.
In this case the scaling must be adjusted by running Unity from the console as follows (where <unity>
is the path to the Unity executable and <SEE>
is the path to the SEE project):
GDK_SCALE=2 GDK_DPI_SCALE=0.5 <unity> -projectpath <SEE>
Scaling factors may need to be adjusted depending on your setup.