AppDelegate setFullscreen:发送到实例的无法识别的选择器

时间:2013-06-18 10:21:30

标签: iphone cocos2d-iphone

我正在尝试在AppDelegate中接收RevMobAdsDelegate事件,并且在调用时遇到运行时信号错误。

[3496:207] [RevMob myapplication App]
SetChartBoostRequestFlag - StopLoadingWait
[3496:207] [RevMob myapplication App] StopLoadingWait routine
[3496:207] [RevMob] Starting RevMobAds
[3496:207] [RevMob] Initializing Fullscreen.
[3496:207] -[AppDelegate setFullscreen:]: unrecognized selector sent to instance    0xa20b4e0
(gdb) 

我已经在我的代码中添加了RevModAds Framework,但它仍然给我这种信号错误。和应用程序在加载起始横幅后崩溃。

我从这里安装了RevMobads sdk     http://sdk.revmob.com/ios.html#fullscreen

2 个答案:

答案 0 :(得分:0)

你的AppDelegate中有setFullscreen:方法吗?如果没有,你最好实现它。文档说有showFullscreen,这是不同的。

答案 1 :(得分:0)

您可以这样做:

  #define REVMOB_APP_ID @"50cd7e844ae728120000003f"

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 
  {  
            [RevMobAds startSessionWithAppID:REVMOB_APP_ID];
            [self showAds];
            ..
            ..
  }

  -(void)showAds  //call this from game over, game pause
  {
            [[RevMobAds session] showFullscreen];
  }