Native
The SDK will handle the native AD loading logic internally, and the game side can call the display/hide native method as needed.
Is Native ad available
var isNativeReady = HCSDKManager.Instance.IsNativeAdReady();
if (isNativeReady)
{
HCDebugger.LogDebug("Native ad is ready ");
}else
{
HCDebugger.LogDebug("Native ad not ready");
}
Showing a Native Ad
public void Button_ShowNative()
{
HCSDKManager.Instance.ShowNative(nativeImage.rectTransform);
}
API:
void ShowNative(RectTransform pRect, Camera pCam = null, string pAdPos = "");
RectTransform :Need to display the RectTransform of the native AD Image.
pCam :If the UI uses camera mode, you must use an orthogonal camera.
pAdPos :Display native ads in the location of the dot.
Native location explanation
Need to show native location:
Removing a Native Ad
public void Button_RemoveNative()
{
HCSDKManager.Instance.RemoveNative();
}