6
SKAction의 repeatActionForever 메서드를 사용하여 SKShapeNode의 색을 변경하고 있습니다.SKAction SKShapeNode의 색을 변경하십시오.
이SKShapeNode *ship = [SKShapeNode node];
[ship setPath:CGPathCreateWithRoundedRect(CGRectMake(-15, -15, 40, 17), 6.25, 6.25, nil)];
ship.fillColor = [SKColor redColor];
ship.glowWidth = 3;
[ship runAction:[SKAction repeatActionForever:[SKAction sequence:@[
[SKAction colorizeWithColor:[SKColor blueColor] colorBlendFactor:1.0 duration:0.5],
[SKAction waitForDuration:0.3],[SKAction colorizeWithColorBlendFactor:1.0 duration:0.5],
[SKAction colorizeWithColor:[SKColor redColor] colorBlendFactor:1.0 duration:0.5],
[SKAction waitForDuration:0.3],
[SKAction colorizeWithColorBlendFactor:1.0 duration:0.5],
[SKAction waitForDuration:0.3]]]]];
return ship; //because it's a method
그것은 바로 내 보이지만 선박이 색상을 변경하지 않습니다 다음은 내 코드입니다. 내가 뭘 잘못 했니, 고마워.