Plugin : Kongregate
Author:Rex.Rainbow
- Api of kongregate. Reference: https://docs.kongregate.com/v1.0/docs/javascript-api
Download
Actions
Authentication
Action:Show registration box
- Show a dialog prompting the user to register an account.
Custom Chat
Action:Show tab
- Displays a custom chat tab.
- Tab name ( string ) : Name of the tab.
- Description ( string ) : Description of the tab.
- Options ( string ) : Extra options for the tab, in JSON
Action:Display message
- Displays a custom chat tab.
- Message ( string ) : The message to display.
Action:Clear messages
- Remove all chat messages from the custom tab.
Action:Close tab
Action:Add event listener
- Listen for chat messages from the user.
- Event ( Combo ) : Type of event to listen for.
- Options : ["message","room.message","tab_visible"]
- Callback ( string ) : A tag, which can be anything you like, to distinguish between different callback.
Feeds & User Messaging
Action:Show feed post box
- Create a post in the user's activity feed.
- Content ( string ) : A string containing the text for the feed post.
- Image URI ( string ) : Link to an image to use as an icon for the feed post.
- kv_params ( string ) : Optional parameters to be passed into the game when the feed post link is followed.
Action:Show shout box
- Post a shout on the user's profile page.
- Message ( string ) : The message text to add to the shout.
Action:Show invitation box
- Post a shout on the user's profile page.
- Content ( string ) : The text content of the invitation.
- Filter ( string ) : One of these values: "", "played", "not_played", a list of userID ex "123 8219"
- kv_params ( string ) : Optional parameters to be passed into the game when the feed post link is followed.
Action:Private message
- Send a private message to the user.
- Content ( string ) : The message to send.
Incentivized Ads
Action:1. Initialize incentivized Ads
- Initialize the incentivized ad system.
Action:3. Show incentivized Ad
- Attempt to display an incentivized ad to the user.
Kreds & Virtual Goods
Action:Request user item list
- Request user item list.
- Callback ( string ) : A tag, which can be anything you like, to distinguish between different callback.
Action:Request item list
- Request item list.
- Tags ( string ) : Item tags, separated by ",".
- Callback ( string ) : A tag, which can be anything you like, to distinguish between different callback.
Action:Purchase items
- Start the purchase flow for predefined items.
- Identifiers ( string ) : Item identifier strings, separated by ",".
- Callback ( string ) : A tag, which can be anything you like, to distinguish between different callback.
Action:Show Kred purchase dialog
- Opens the Kred Purchase lightbox.
- Type ( Combo ) : Optional type of offer to display.
- Options : ["default","OfferPal","Mobile/Zong"]
Shared Content
Action:Save
- Save a custom level or other shared content.
- type ( string ) : Type of content the user wishes to save, 12 characters max.
- Content ( string ) : Value of content to be saved.
- Label ( string ) : Optional label for sub-classing the shared content.
- Callback ( string ) : A tag, which can be anything you like, to distinguish between different callback.
Action:Browse
- Allow the player to browse shared content.
- type ( string ) : Type of content the user wishes to save, 12 characters max.
- Sort by ( Combo ) : How to sort the content.
- Options : ["own","newest","load count","friends"]
- Label ( string ) : Optional label for sub-classing the shared content.
Action:Add load listener
- Receive notifications when shared content is loaded.
- type ( string ) : Type of content to listen for.
- Callback ( string ) : A tag, which can be anything you like, to distinguish between different callback.
Statistics
Action:Submit
- Submit statistics/scores to the server.
- Statistic name ( string ) : The name of the statistic to submit.
- Value ( number ) : The value of the statistic to submit.
Expressions
Authentication
Expression:UserID
- Return the current user's ID, or 0 if guest.
Expression:UserName
- Return the current user's name, or a guest name if not logged in.
Expression:GameAuthToken
- Get the game authentication token for the current user.
Callback
Expression:Result
- Get result of callback, in JSON string.
Conditions
API Load
Condition:On api loaded
- Triggered when api loaded.
Condition:Is api loaded
- Return true if api is loaded.
Authentication
Condition:On login
- Triggered when the user logs in (either automatically or during the game).
Condition:Is guest
- True if the user is a guest (not logged in).
Callback
Condition:Callback
- Callback of request.
- Callback ( string ) : A tag, which can be anything you like, to distinguish between different callback.
Incentivized Ads
Condition:2. On ads available
- Triggered when ads is available.
Condition:2. On ads unavailable
- Triggered when ads is unavailable.
Condition:4. On ads opened
- Triggered when ads is opened.
Condition:5. On ads completed
- Triggered when ads is completed.
Condition:5. On ads abandoned
- Triggered when ads is abandoned.