Go to file
xiaoyi e6df19fa36 feat: update release native binary 2021-06-10 11:12:59 +08:00
Documentation feat(*): update binary 2021-05-14 19:16:05 +08:00
Editor feat (bootstrap) : update TapConfig constructor func 2021-04-25 15:45:36 +08:00
Plugins feat: update release native binary 2021-06-10 11:12:59 +08:00
CHANGELOG.md feat: update release native binary 2021-06-10 11:12:59 +08:00
CHANGELOG.md.meta feat(*): update namespace to TapTap.ModuleName 2021-04-07 16:20:41 +08:00
Documentation.meta feat(tapdb): add dynamicProperties interface 2021-04-14 13:46:30 +08:00
Editor.meta feat(*): update namespace to TapTap.ModuleName 2021-04-07 16:20:41 +08:00
Plugins.meta mod:replace all framework 2021-04-08 10:11:23 +08:00
README.md feat(*): update binary 2021-05-14 19:16:05 +08:00
README.md.meta feat(*): update namespace to TapTap.ModuleName 2021-04-07 16:20:41 +08:00
VERSIONNOTE.md feat: update release native binary 2021-06-10 11:12:59 +08:00
VERSIONNOTE.md.meta feat: update release native binary 2021-06-10 11:12:59 +08:00
package.json feat: update release native binary 2021-06-10 11:12:59 +08:00
package.json.meta feat(*): update namespace to TapTap.ModuleName 2021-04-07 16:20:41 +08:00

README.md

使用 TapTap.Bootstrap

使用前提

使用 TapTap.Bootstrap 前提是必须依赖以下库:

命名空间

using TapTap.Bootstrap;

接口描述

1.初始化

TapBootstrap 会根据 TapConfig 中的 TapDBConfig 配置来进行 TapDB 的自动初始化。

开启 TapDB

var config = new TapConfig.TapConfigBuilder()
                .ClientID("client_id")
                .ClientSecret("client_secret")
                .RegionType(RegionType.CN)
                .TapDBConfig(true,"channel","gameVersion",true)
                .Builder();

关闭 TapDB

var config = new TapConfig.TapConfigBuilder()
                .ClientID("client_id")
                .ClientSecret("client_secret")
                .RegionType(RegionType.CN)
//#             .TapDBConfig(false,null,null,false)
                .EnableTapDB(false)
                .Builder();

初始化 TapSDK

TapBootstrap.Init(config);

2.登陆

TapBootstrap.Login(LoginType loginType, string[] permissions);

3.设置语言

TapBootstrap.SetPreferLanguage(TapLanguage tapLanguage);

4.绑定TapTap账号已废弃

TapBootstrap.Bind(LoginType loginType, string[] permissions);

5.注册用户状态回调

TapBootstrap.RegisterUserStatusChangedListener(ITapUserStatusChangedListener listener); 

6.注册登陆回调

TapBootstrap.RegisterLoginResultListener(ITapLoginResultListener listener);

7.获取用户信息

TapBootstrap.GetUser(Action<TapUser,TapError> action);

8.获取详细用户信息

TapBootstrap.GetDetailUser(Action<TapUserDetail, TapError> action);

9.篝火测试资格

TapBootstrap.GetTestQualification(Action<bool,TapError> action);

10.获取AccessToken

TapBootstrap.GetDetailUser(Action<TapUserDetail, TapError> action);

11.登出

TapBootstrap.Logout();