I’m trying to use the function “cc.Application.getCurrentLanguage” for getting the lang of the user on iOS, but the function doesn’t exist.
I’m using cocos2d-html5-2.1.3 and cocos2d-x-2.1.3
On html5 works fine, but on jsbinding this function returns me this error.
Any date for implementing this function?
You could use cc.Application.getInstance.getCurrentLanguage* instead.
For short-term solution, to be compatible with cocos2d-html5, you should addcc.Application.getCurrentLanguage = cc.Application.getInstance().getCurrentLanguage* to scripting/javascript/bindings/js/jsb_cocos2d.js.
1 Like
Thank’s for the tip.
I will try this solution on a few days.
cc.Application.getInstance().getCurrentLanguage() works fine on iOs, but this solution doesn’t work on cocos2d-html5
I need to manually select cc.Application.getInstance().getCurrentLanguage() or cc.Application.getCurrentLanguage()
I will wait for the next cocos2d family release.