This article describes how to interface with the Miracle Games SDK's community interface
This interface is managed by MiracleGames, if you need to open the community function, you need to contact MG staff in advance to help open!
The premise of the community function is that the account must be logged in successfully, so it is usually in the logic of logging in successfully that the social function call code is added.
public MainPage()
{
this.InitializeComponent();
Loaded += (sender, args) =>
{
var auth = await MiracleGames.AuthenticationManager.AuthenticateAsync();//enable login
if (auth.ReturnValue)//Login successful..
{
//var uid = MiracleGames.AuthenticationManager.UserInfo.Id;
//var token = MiracleGames.AuthenticationManager.UserInfo.Token;
//Show user center bubble.
MiracleGames.BubbleManager.ShowBubble();//Enable community function
}
};
}
The event callback functionality of the Community and Scorewall can be achieved by registering delegated events directly in the application.
MiracleGames.BubbleManager.BubbleIntegralWallRewardsChanged += BubbleManager_BubbleIntegralWallRewardsChanged;//Wall of Points app install reward callbacks
private void BubbleManager_BubbleIntegralWallRewardsChanged(object sender, string e)
{
throw new NotImplementedException();
}
MiracleGames.BubbleManager.BubbleIntegralWallFirePwChangeEvents += BubbleManager_BubbleIntegralWallFirePwChangeEvents;//Wall of Points Task Completion Reward Callbacks
private void BubbleManager_BubbleIntegralWallFirePwChangeEvents(object sender, string e)
{
throw new NotImplementedException();
}
MiracleGames.BubbleManager.BubbleOpenCloseEvent += BubbleManager_BubbleOpenCloseEvent;//bubble open close callbacks
private void BubbleManager_BubbleOpenCloseEvent(object sender, bool e)
{
ShowFullScreenInterstitialAd();
throw new NotImplementedException();
}