Steam ログイン方法を設定する - Steam でログインする - (Unity モジュール)
This tutorial module does not apply to WebGL builds due to limitations in Steamworks.
Set up Steam login method in the Admin Portal
In this tutorial, you will learn how to add a Steam login method in the AccelByte Gaming Services (AGS) Admin Portal.
Log in to the Admin Portal and go to your game namespace dashboard.
Go to select Game Setup > 3rd Party Configuration > Auth & Account Linking and click Add New.
Click Steam SDK and fill out the form that appears:
- App ID: Your game's App ID from the Steam partner dashboard (see Applications from Steam).
- Steam Web API Key: The Web API Key acquired from Steam (see Steam Web API Documentation).
- Redirect URI: Enter
http://127.0.0.1
- When redirected to the Login Platform Configuration page, verify its Status is Active. If it's not, activate it by clicking Activate once, and again on the pop-up to confirm.
Configure Steam
In this tutorial, you will learn how to enable Steamworks SDK.
Open the project in the Unity Editor. Then, open the
TutorialModuleConfig.json
file located atAssets/Resources/Modules/TutorialModuleConfig.json
. This file is a configuration specific to Byte Wars.In the
TutorialModuleConfig.json
file, add your Steam App ID to thesteamAppId
field. If you want the game to automatically log in using Steam when it starts, you can set theautoLogin
option totrue
.{
...
"singlePlatformAuth": "Steam",
"steamConfiguration": {
"steamAppId": "replace with your steam app id",
"autoLogin": false
}
...
}備考Byte Wars uses the values from
TutorialModuleConfig.json
to configure Steamworks.NET.
To learn more about working with Steamworks.NET in Unity, check out the Steamworks.NET documentation.Next, open the Steam client on your computer.
Go back to the Unity Editor and make sure to open the
MainMenu.unity
located in theAssets/Scenes/MainMenu.unity
.Then, play the game from the Unity Editor. If you've launched the Steam client and configured the App ID correctly, you will see the following log:
[Steamworks.NET] SteamAPI_Init() success