Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rgl/unity-example-windows-vagrant
a simple Unity example that shows a cube
https://github.com/rgl/unity-example-windows-vagrant
example unity unity3d vagrant
Last synced: 12 days ago
JSON representation
a simple Unity example that shows a cube
- Host: GitHub
- URL: https://github.com/rgl/unity-example-windows-vagrant
- Owner: rgl
- Created: 2018-04-21T20:23:42.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2019-07-27T12:09:27.000Z (over 5 years ago)
- Last Synced: 2024-10-26T13:06:52.303Z (2 months ago)
- Topics: example, unity, unity3d, vagrant
- Language: PowerShell
- Size: 28.3 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
This is a simple Unity example that shows a cube.
You can move the cube around by using the arrow keys.
# Vagrant Environment
After a `vagrant up` you should have a VM with Unity installed. You still need to
[activate](https://docs.unity3d.com/Manual/LicensesAndActivation.html) it by
launching Unity Hub from the Desktop shortcut.After Unity is activated, you can build `Build\Cube.exe` from the command line with:
```powershell
# build the project.
# NB this only succeeds after Unity is activated (when its
# activated a C:\ProgramData\Unity\Unity_lic.ulf file exists).
# NB the scenes to be built must be declared inside the
# ProjectSettings/EditorBuildSettings.asset file.
# You can do this in Unity, by selecting the File | Build Settings
# menu and clicking the "Add Open Scenes" button.
# see https://docs.unity3d.com/Manual/CommandLineArguments.html
&'C:\Program Files\Unity\Editor\Unity.exe' `
-batchmode `
-quit `
-logFile - `
-projectPath $PWD `
-buildWindows64Player "$PWD\Build\Cube.exe" `
| Out-String -Stream
if ($LASTEXITCODE) {
throw "Build failed with exit code $LASTEXITCODE"
}
```# Notes
* To use unity from a non-administrator account you need to grant it the `Remote Enable` permission to the `ROOT\CIMV2` WMI namespace. For example, to run from Jenkins see [rgl/jenkins-vagrant](https://github.com/rgl/jenkins-vagrant/blob/master/windows/provision-unity.ps1) for more details.
* To manage multiple Unity instances try to use one of:
* https://github.com/DragonBox/u3d
* https://github.com/Microsoft/unitysetup.powershell