KongMobile Class Reference

Inherits from NSObject
Declared in KongMobile.h

Overview

This interface handles mobile-specific issues such as UI and opening the Kongregate panel.

– orientButtonToScreen

Attempts to orient the Kongregate button to the screen. This can be useful after detecting a rotation.

- (void)orientButtonToScreen

Declared In

KongMobile.h

– openKongregateWindow

Opens the Kongregate window

- (void)openKongregateWindow

Declared In

KongMobile.h

– openKongregateWindow:

Opens the Kongregate window with a target

- (void)openKongregateWindow:(NSString *)target

Parameters

target

The target to open the window with. (e.g. KONG_MOBILE_TARGET_FORUMS)

Declared In

KongMobile.h

– openKongregateWindow:withId:

Opens the kongregate window with a target and index. For example, a specific topic.

- (void)openKongregateWindow:(NSString *)target withId:(NSString *)targetId

Parameters

target

The target page to open the panel to (e.g. KONG_MOBILE_TARGET_TOPICS)

targetId

The ID to open within the target (e.g. 1234)

Declared In

KongMobile.h

– closeKongregateWindow

Close webview

- (void)closeKongregateWindow

Declared In

KongMobile.h

– isKongregateWindowOpen

Check if the Kongregate Window is currently open

- (BOOL)isKongregateWindowOpen

Declared In

KongMobile.h

– getButton

Gets an instance of the Kongregate button to add to your layout. The size will be either 32, 48, or 64 pixels depending on the device.

- (UIButton *)getButton

Return Value

The button

Declared In

KongMobile.h

– getButton:

Gets an instance of the Kongregate button to add to your layout. Valid sizes are 32, 48, and 64.

- (UIButton *)getButton:(int)size

Parameters

size

The size of the button (32/48/64)

Return Value

The button

Declared In

KongMobile.h

– trackPurchase:withQuantity:

see KongAnalytics finishPurchase (Deprecated: see KongAnalytics finishPurchase)

- (void)trackPurchase:(NSString *)productID withQuantity:(int)quantity

Parameters

productID

the product ID

quantity

the quantity

Declared In

KongMobile.h

– trackPurchase:

see KongAnalytics finishPurchase (Deprecated: see KongAnalytics finishPurchase)

- (void)trackPurchase:(NSString *)productID

Parameters

productID

the product ID

Declared In

KongMobile.h

– getOpenURL

Return the URL used to open the app when launched or brought to the foreground using a deep link. The {@link KongregateAPI#KONGREGATE_EVENT_DEEP_LINK} will be fired as well. Will return nil for standard app launches.

- (NSURL *)getOpenURL

Declared In

KongMobile.h

– trigger:

Triggers an event from the game to the Kongregate SDK

- (void)trigger:(NSString *)name

Parameters

name

the event to send to the Kongregate SDK

Declared In

KongMobile.h