#Senspark Plugins
Senspark Plugin provides common utilities for developers to use in game across different platforms with cocos2d-x.
This plugin is developed basing on Plugin-x, which provides an easy way for developers to integrate various third party SDKs.
One unified API for all SDKs
- Ads
- Analytics
- BaaS (Backend as a Service)
- Data
- IAP (comming soon)
- Sharing
- Social
-
Prerequisites
-
Define environment variable
COCOS2DX_ROOT
in/etc/launchd.conf
(using this help) -
Put this line in ~/.profile file
grep -E "^setenv" /etc/launchd.conf | xargs -t -L 1 launchctl
-
-
...
-
Providers
- Flurry Analytics
- Google Analytics
-
Using
-
Example
auto manager = SensparkPluginManager::getInstance(); auto pluginProtocol = manager->loadAnalyticsPlugin(AnalyticsPluginType::GOOGLE_ANALYTICS); auto googleAnalytics = static_cast<GoogleProtocolAnalytics*>(pluginProtocol)
-
- Providers
- Admob
- AdColony
- Facebook Ads
- Tapjoy
- Vungle
- Using
-
Example
auto manager = SensparkPluginManager::getInstance(); auto pluginProtocol = manager->loadAnalyticsPlugin(AdsPluginType::ADMOB); auto admobAd = static_cast<AdmobProtocolAds*>(pluginProtocol)
-