Your work isn’t worth much in the context of scientific research if it can’t be reproduced and used by others. To facillitate this, it is very important to condense the important parts of your work into easily implementable Unity packages. This page explains roughly the process on how we do this in the MLN Lab.
Additionally, it is important you upload the full Unity project on the GitLab organisation as well. See here for a guide on how to do this.
The method summarized here is based on the following youtube tutorial:
For an example package, look at the MLNLab UDP Package.
See here for the official Unity documentation.
com.mlnlab.<pkg name>/
Runtime/
- Contains all runtime scripts, also contains the assembly definition (mlnlab.<pkg name>.asmdef
, see below for an example).Editor/
- Contains all your editor filespackage.json
- Contains the basic info about your package. See below for an example.git init
git remote add origin git@gitlab.tudelft.nl:mln-lab/unity/<pkg name>.git`
git branch -M main
git checkout -b dev
git add -A
git commit -m "Initial package files"
git push -uf origin dev
{
"name": "com.mlnab.udp",
"version": "1.0.0",
"displayName": "MLNLab UDP",
"description": "Package for handling UDP communication at MLNLab. (https://www.mlnlab.nl)",
"unity": "2022.2",
"unityRelease": "0b16",
"keywords": [
"UDP",
"communication",
"mlnlab"
],
"author": {
"name": "MLN Lab",
"email": "A.vandenberg-2@tudelft.nl",
"url": "https://www.mlnlab.nl"
},
"repository": {
"type": "git",
"url": "",
"revision": ""
}
}
{
"name": "mlnlab.udp",
"rootNamespace": "MLNLab",
"references": [],
"includePlatforms": [],
"excludePlatforms": [],
"allowUnsafeCode": false,
"overrideReferences": false,
"precompiledReferences": [],
"autoReferenced": true,
"defineConstraints": [],
"versionDefines": [],
"noEngineReferences": false
}
Go to Unity --> Window/Package Manager
, click the + in the top left, click Add package from git url...
, paste in the URL.
It is vital to write a good readme file for your Unity package. This readme could also point to another place which contains the documentation for your package.
Ideally your readme should explain:
TO DO: add example readme for MLN Lab.
Link your package on this wiki in the Unity Packages page. If you wish to supply more information on the wiki itself, create a page on the wiki and link that.
If may be desired to publish the package publicly somewhere (the GitLab page is entirely private). A good place for this can be the HRI GitHub Page. Contact for this should go through your supervisor first.