iphone - OpenFeint is on only half of the screen -
iphone - OpenFeint is on only half of the screen -
i'm trying implement openfeint in cocos2d iphone game, here's weird didn't find how solve. here's how openfeint looks when initialize it: http://img842.imageshack.us/img842/8564/screenshot20100926at520.png , here's code of initialization:
[director setdeviceorientation:kccdeviceorientationlandscapeleft]; nsdictionary* settings = [nsdictionary dictionarywithobjectsandkeys: [nsnumber numberwithint:uiinterfaceorientationlandscapeleft], openfeintsettingdashboardorientation, @"name", openfeintsettingshortdisplayname, [nsnumber numberwithbool:no], openfeintsettingenablepushnotifications, [nsnumber numberwithbool:yes], openfeintsettingalwaysaskforapprovalindebug, [nsnumber numberwithbool:yes], openfeintsettingdisableusergeneratedcontent, nil]; [openfeint initializewithproductkey:@"productkey" andsecret:@"secret" anddisplayname:@"name" andsettings:settings anddelegates: [ofdelegatescontainer containerwithopenfeintdelegate:self]]; [[ccdirector shareddirector] runwithscene: [mainmenuscene node]];
i've seen post in few places having same problem were. figured out potential solution , thought reply. seems on occasions openfeint unable access keywindow , in case creates it's own window may not deed yours has been set do. solution allow openfeint know window go after adding settings. settings below , can see added "openfeintsettingpresentationwindow" setting keyed window. after doing worked wonderfully. hope helps!
nsdictionary* settings = [nsdictionary dictionarywithobjectsandkeys: [nsnumber numberwithint:uiinterfaceorientationlandscaperight], openfeintsettingdashboardorientation, window, openfeintsettingpresentationwindow, @"comingsoon", openfeintsettingshortdisplayname, [nsnumber numberwithbool:yes], openfeintsettingenablepushnotifications, nil];
iphone openfeint
Comments
Post a Comment