KIDOZ Unity SDK Sample App
Updated to KIDOZ Android SDK version 0.7.0 iOS SDK version 0.5.7
KIDOZ SDK and the sample App are compatible with Android 4.0 (API level 14) and above and Unity versions greater than 5
When comming from a previous version, please manually delete the Plugins/Android/KidozSdk/libs/okhttp-2.5.0.jar file, since we are updated to 3.4.0 version
When comming from a previous version, please manually delete the Plugins/Android/KidozSdk/libs/okhttp-2.7.0.jar file, since we are updated to 3.0.1 version
When comming from a previous version, please manually delete the Kidoz.cs located in the root assetes folder , since we moved the file postion. also make sure that teh KidozObject points to the new Kidoz script
Please make sure that the activity in the manifest is defined as com.unity3d.player.UnityPlayerActivity
When compiling for iOS please add the following frameworks: libsqlite3.tbd, webkit.framework
This Unity application project provides an example of the KIDOZ SDK integration.
The example application contains the following creative tools:
- KIDOZ Panel view
- KIDOZ Interstitial view
- KIDOZ Feed view content tool - the
- KIDOZ default button - the
- KIDOZ Banner view
- KIDOZ Flexi view
Running the sample app
- Clone (or Download) the Unity project (download button located on the right) and unzip the downloaded .zip file
Open, navigate to unzipped project directory, select the whole directory and click
- In the Assets tab click on the
FirstScene(See printscreen below)
- Go to
Build Settings..., in the opened menu select
- To run the SDK Sample App go to
Build & Run
KIDOZ SDK - Getting Started
This demo application uses
buildToolsVersion "22.0.1". if your
Android Studio is not updated with this version you can follow one of these steps (or both):
Android Studioclick the
- In the left side menu, navigate to
Appearance & Behavior-->
- Click the
- Check the
Android SDK Build Toolsand click
- Import the
Custom Package--> select the extracted KidozSDK package.
- In the import window select all components. A new Prefabs object named
KidozObjectwill appear in the Assets folder.
- Open your requested Scene.
- Drag the
KidozObjectinto the selected scene.
- Select the
KidozObjectand enter your
Using the SDK
- Select your relevant script file.
using KidozSDK;in the using section of your code.
- Create two listeners with the following signature
One for Feed open and one for Feed close.
- Connect the two listeners function you created to
- Create two listeners with the following signature
void functionName(string)for movie open and movie close
- Connect the above listeners to
PanelView is a customized special view that can slide in/out of the screen (both in horizontal and vertical layout) with minimal interference to user experience.
PanelView can be placed on one of four sides of the activity screen -
PanelView can be controlled via a special
Handle button that can be located in any of the 3 following positions -
HANDLE_POSITION.END depending on the
PanelView initial screen location.
to activate the panel use the following function:
Kidoz.addPanelToView (Panel_type, Handle_Position);
You can also expand the panel programmatically by using the following function:
Kidoz.expandPanelView() and collapse the panel by using the following function <\br>
KIDOZ Interstitial / Rewarded View
KidozInterstitial is a full screen single ad unit which can be used as simple interstitial or rewared mode.
You can activate the interstitial widget by first calling the load function
To request rewarded ad call this function
The second stage after the ad was loaded (using the Kidoz.interstitialReady listener you can call
It is possible to test if the ad was loaded using the following function:
all listeners are of type: private void listenerName(string value) Kidoz.bannerReady += bannerReady;
Kidoz.interstitialOpen += listenerName; Kidoz.interstitialClose += listenerName; Kidoz.interstitialReady += listenerName; Kidoz.interstitialOnLoadFail += interstitialOnLoadFail; Kidoz.onRewardedDone += onRewardedDone; Kidoz.onRewardedVideoStarted += onRewardedVideoStarted;
#KIDOZ Feed ###Calling the Feed View Programmatically You can display the feed view programmatically by calling the following method: ```Kidoz.showFeedView()
to close the feed view call
Adding the KIDOZ Feed Button
Kidoz.addFeedButton(int xPos, int yPos)which will place KIDOZ top left corner button at the selected coordinates. The button size can be found using the following message:
Kidoz.getFeedButtonDefaultSize()which will return an int number that represents the width and height of the button.
Kidoz.addFeedButton(int xPos, int yPos, int size)that will place KIDOZ top left corner button at the selected coordinates with the requested size. The same size applies for both the width and height of the button.
The visibilty of the button can be controlled using the following function:
KIDOZ Flexi Point View *only in Android
You can add the
FlexiView by calling the following function:
Kidoz.addFlexiView (bool<auto show>, Kidoz.FLEXI_VIEW_POSITION<the flexi view start position);
To Show/Hide Flexi view use the following lines:
// Show flexi view Kidoz.showFlexiView(); // Hide flexi view Kidoz.hideFlexiView();
To add event listeners to Flexi View use: ``` All listeners are of type: private void listenerName(string value)
Kidoz.flexiViewReady += listenerName;
Kidoz.flexiViewShow += listenerName;
Kidoz.flexiViewHide += listenerName;
For any question or assistance, please contact us at SDK@kidoz.net.
Copyright 2015 KIDOZ, Inc. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.