gpt4 book ai didi

iphone - OpenFeint 仅显示在屏幕的一半上

转载 作者:行者123 更新时间:2023-12-03 20:57:43 26 4
gpt4 key购买 nike

我正在尝试在我的 Cocos2D iPhone 游戏中实现 OpenFeint,但有一些奇怪的事情我没有找到解决方法。这是我初始化 OpenFeint 时的样子: http://img842.imageshack.us/img842/8564/screenshot20100926at520.png这是初始化的代码:

[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]];

最佳答案

我在几个地方看到过你的帖子,因为我遇到了和你一样的问题。我刚刚为你找到了一个可能的解决方案,并想我会回复你。似乎在某些情况下 OpenFeint 无法访问键窗口,在这种情况下,它会创建自己的窗口,该窗口可能不会像您设置的那样运行。解决方案是通过将其添加到设置中来让 OpenFeint 知 Prop 体要跟踪哪个窗口。我的设置如下,如您所见,我使用键控窗口添加了“OpenFeintSettingPresentationWindow”设置。这样做之后,效果非常好。希望这有帮助!

NSDictionary* settings = [NSDictionary dictionaryWithObjectsAndKeys:
[NSNumber numberWithInt:UIInterfaceOrientationLandscapeRight], OpenFeintSettingDashboardOrientation,
window, OpenFeintSettingPresentationWindow,
@"ComingSoon", OpenFeintSettingShortDisplayName,
[NSNumber numberWithBool:YES], OpenFeintSettingEnablePushNotifications,
nil];

关于iphone - OpenFeint 仅显示在屏幕的一半上,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3800237/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com