我是 Cocos2D 的新手,我现在正在尝试 ABC123(从互联网下载,由 kwigbo 创建)我想知道为什么它在模拟器上一切正常,但是当我使用我的 iPad 测试它时....问题来了up..我尝试了2周但仍然无法解决...希望有人能教我吗??非常感谢....
本来泡泡会在玩家记住单词的位置后出现,但是使用iPad运行时……启动后很快就会出现泡泡,玩家完全不记得单词的位置来玩游戏了……
我试图将延迟部分从 delayTime = 1.5 更改为 4;:
@GameLayer.m
float delayTime = 4.0;
if(dataManager.currentlevel > 10) delayTime = 2.5;
[self runAction:[Sequence actions:[DelayTime actionWithDuration:delayTime], [CallFunc actionWithTarget:self selector:@selector(showBubbles)], nil]];
它在模拟器中延迟,但在 iPad 中没有改变......
与 OrbSprite.m 有什么关系吗?
@OrbSprite.m 的初始化:
Label *l = [[Label alloc] initWithString:@"" dimensions:CGSizeMake(50, 50) alignment:UITextAlignmentCenter fontName:@"Arial Rounded MT Bold" fontSize:45];
self.label = l;
[l release];
//[self initWithFile:@"bubble1.png"];
Animation *bub = [Animation animationWithName:@"bubble" delay:1.0f images:@"bubble1.png", @"bubble2.png", nil];
self.bubble = bub;
[bub release];
[self addAnimation:bubble];
或者我应该在这条线上做什么?
- (void) showBubble
{
isBubble = YES;
[self setDisplayFrame:@"bubble" index:1];
self.scale = .1;
[self runAction:[Sequence actions: [ScaleTo actionWithDuration:.1 scale:0.1], [ScaleTo actionWithDuration:.1 scale:1], nil]];
[self removeChild:label cleanup:YES];
}