Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Unity Package Manager #2343

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
f2f7809
Add files to support Unity Package Manager
aaronchapin-tocaboca Oct 27, 2021
7873509
Update version number
aaronchapin-tocaboca Oct 27, 2021
64f7b52
Merge branch 'main' into feature/issue-2338-unity-package
aaronchapin-tocaboca Oct 28, 2021
c05ae95
Update author name
aaronchapin-tocaboca Oct 29, 2021
5ac61b9
Merge branch 'feature/issue-2338-unity-package' of github.com:aaronch…
aaronchapin-tocaboca Oct 29, 2021
2b2969e
Merge branch 'main' into feature/issue-2338-unity-package
aaronchapin-tocaboca Oct 29, 2021
931ce7d
Add update step
aaronchapin-tocaboca Nov 1, 2021
8a59ace
Merge branch 'feature/issue-2338-unity-package' of github.com:aaronch…
aaronchapin-tocaboca Nov 1, 2021
34c3440
Merge branch 'main' into feature/issue-2338-unity-package
roberthbailey Nov 3, 2021
c94f5ad
Add step to Update SDK Package Versions section
aaronchapin-tocaboca Nov 8, 2021
bd54e7b
Merge branch 'main' of github.com:googleforgames/agones into feature/…
aaronchapin-tocaboca Nov 8, 2021
5669bda
Merge branch 'feature/issue-2338-unity-package' of github.com:aaronch…
aaronchapin-tocaboca Nov 8, 2021
3daebb4
Merge branch 'main' into feature/issue-2338-unity-package
markmandel Nov 8, 2021
1cb6f35
Updated client SDK documentation
aaronchapin-tocaboca Nov 12, 2021
14c745a
Merge branch 'main' of github.com:googleforgames/agones into feature/…
aaronchapin-tocaboca Nov 12, 2021
a5d7c90
Merge branch 'feature/issue-2338-unity-package' of github.com:aaronch…
aaronchapin-tocaboca Nov 12, 2021
eb6e856
Merge branch 'main' into feature/issue-2338-unity-package
markmandel Nov 15, 2021
7602eca
Merge branch 'main' into feature/issue-2338-unity-package
markmandel Nov 15, 2021
3c99121
Merge branch 'main' into feature/issue-2338-unity-package
markmandel Nov 16, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions docs/governance/templates/release_issue.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ and copy it into a release issue. Fill in relevant values, found inside {}
- [ ] Update SDK Package Versions
- [ ] Update the package version in [`sdks/nodejs/package.json`][package.json] and [`sdks/nodejs/package-lock.json`][package-lock.json] by running `npm version {version}` if a full release or `npm version {version}-rc` if release candidate
- [ ] Ensure the [`sdks/csharp/sdk/AgonesSDK.nuspec` and `sdks/csharp/sdk/csharp-sdk.csproj`][csharp] versions are correct (should be {version} if a full release, {version}-rc if release candidate)
- [ ] Update the package version in the [`sdks/unity/package.json`][unity] package file's `Version` field to {version} if a full release, {version}-rc if release candidate
- [ ] Run `make gen-install`
- [ ] Run `make test-examples-on-gcr` to ensure all example images exist on gcr.io/agones-images-
- [ ] Create a *draft* release with the [release template][release-template]
Expand Down Expand Up @@ -80,6 +81,7 @@ and copy it into a release issue. Fill in relevant values, found inside {}
- [ ] If full release move the [helm `Chart` version values][chart] is to {version}+1-dev
- [ ] If full release, change to the `sdks/nodejs` directory and run the command `npm version {version}+1-dev` to update the package version
- [ ] If full release move the [`sdks/csharp/sdk/AgonesSDK.nuspec` and `sdks/csharp/sdk/csharp-sdk.csproj`][csharp] to {version}+1-dev
- [ ] If full release update the [`sdks/unity/package.json`][unity] package file's `Version` field to {version}+1-dev
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should also add a checklist item in the Update SDK Package Versions section as well to increment the Unity version 👍🏻

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done 👍

- [ ] If full release, remove `feature-freeze-do-not-merge` labels from all pull requests
- [ ] Run `make gen-install gen-api-docs`
- [ ] Create PR with these changes, and merge them with approval
Expand Down
3 changes: 3 additions & 0 deletions sdks/unity/Agones.asmdef
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"name": "Agones"
}
7 changes: 7 additions & 0 deletions sdks/unity/Agones.asmdef.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions sdks/unity/AgonesSdk.cs.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions sdks/unity/model.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions sdks/unity/model/GameServer.cs.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions sdks/unity/model/GameServerObjectMeta.cs.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions sdks/unity/model/GameServerSpec.cs.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions sdks/unity/model/GameServerStatus.cs.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions sdks/unity/model/SpecHealth.cs.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions sdks/unity/model/StatusPort.cs.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions sdks/unity/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"name": "com.googleforgames.agones",
"version": "1.18.1",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this the version of Unity it works with, or is this the version of Agones it corresponds to?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This would be the version of Agones that the package corresponds to.

A complete list of all the properties and their descriptions can be found here: https://docs.unity3d.com/Manual/upm-manifestPkg.html

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That page says that the version must be MAJOR.MINOR.PATCH but also says it can follow semantic versioning, which would allow us to have this version match what we use elsewhere, e.g. 1.19.0-dev (then 1.19.0-rc, then 1.19.0, then 1.20.0-dev, and so on).

Do you know if unity will work correctly with our semantic versioning scheme.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I answered this question in another thread, but just to have the info here as well: I tested this semantic versioning scheme and it is supported.

"displayName": "Agones Unity SDK",
"description": "The Unity Gameserver SDK for Agones",
"unity": "2019.1",
"author": {
"name": "Google LLC",
"url": "https://github.com/googleforgames/agones"
}
}
7 changes: 7 additions & 0 deletions sdks/unity/package.json.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions sdks/unity/third_party.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions sdks/unity/third_party/MiniJSON.cs.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

19 changes: 19 additions & 0 deletions site/content/en/docs/Guides/Client SDKs/unity.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,25 @@ Additional methods have been added for ease of use:

- Connect

{{% feature publishVersion="1.19.0" %}}
## Installation

The client SDK code can be manually downloaded and added to your project hierarchy.

It can also be imported into your project via the Unity Package Manager (UPM). To do that, open your project's `manifest.json` file, and add the following line to the dependencies section:

```
{
"dependencies": {
"com.googleforgames.agones": "https://github.com/googleforgames/agones.git?path=/sdks/unity",
...
```

If you want a specific release, the dependency can be pinned to that version. For example:

`"com.googleforgames.agones": "https://github.com/googleforgames/agones.git?path=/sdks/unity#1.19.0",`
{{% feature publishVersion="1.19.0" %}}

## Download

Download the source {{< ghlink href="sdks/unity" >}}directly from GitHub{{< /ghlink >}}.
Expand Down