diff --git a/UnitTests/CCAnimationTest.m b/UnitTests/CCAnimationTest.m index f9943b587c1..1379d767166 100644 --- a/UnitTests/CCAnimationTest.m +++ b/UnitTests/CCAnimationTest.m @@ -9,8 +9,8 @@ #import #import "cocos2d.h" #import "CCAnimationManager.h" -#import "CCBSequence.h" -#import "CCBKeyframe.h" +#import "CCSequence.h" +#import "CCKeyframe.h" #import "CCAnimationManager_Private.h" #define NUM_ELEMENTS(array) (sizeof(array)/sizeof(array[0])) @@ -60,14 +60,14 @@ - (void)testSmallKeyframesTest node.position = ccp(0.0f,0.0f); - CCBSequence* seq = [[CCBSequence alloc] init]; + CCSequence* seq = [[CCSequence alloc] init]; seq.duration = 5.0f; seq.name = @"TestSequence"; seq.sequenceId = 0; seq.chainedSequenceId = 0; [animationManager.sequences addObject:seq]; - CCBSequenceProperty* seqProp = [[CCBSequenceProperty alloc] init]; + CCSequenceProperty* seqProp = [[CCSequenceProperty alloc] init]; seqProp.name = @"position"; seqProp.type = 0; @@ -84,10 +84,10 @@ - (void)testSmallKeyframesTest for (int k = 0; k < numKeyframes; k++) { - CCBKeyframe* keyframe = [[CCBKeyframe alloc] init]; + CCKeyframe* keyframe = [[CCKeyframe alloc] init]; keyframe.time = (float)k * seq.duration / (float)(numKeyframes - 1); - keyframe.easingType = kCCBKeyframeEasingLinear; + keyframe.easingType = kCCKeyframeEasingLinear; keyframe.easingOpt = 0; keyframe.value = points[k]; @@ -145,7 +145,7 @@ - (void)testSmallKeyframesTest const int kSequencerID = 0; //for now; - CCBSequenceProperty* seqProp = [[CCBSequenceProperty alloc] init]; + CCSequenceProperty* seqProp = [[CCSequenceProperty alloc] init]; seqProp.name = @"position"; seqProp.type = 0; @@ -153,10 +153,10 @@ - (void)testSmallKeyframesTest for (int k = 0; k < count; k++) { - CCBKeyframe* keyframe = [[CCBKeyframe alloc] init]; + CCKeyframe* keyframe = [[CCKeyframe alloc] init]; keyframe.time = keyframes[k].time; - keyframe.easingType = kCCBKeyframeEasingLinear; + keyframe.easingType = kCCKeyframeEasingLinear; keyframe.easingOpt = 0; keyframe.value = @[@(keyframes[k].position.x),@(keyframes[k].position.y)]; @@ -175,7 +175,7 @@ - (void)testSmallKeyframesTest - (void)testAnimationSync { CCAnimationManager * animationManager = [[CCAnimationManager alloc] init]; - CCBSequence* seq = [[CCBSequence alloc] init]; + CCSequence* seq = [[CCSequence alloc] init]; seq.duration = 4.0f; seq.name = @"TestSequence"; seq.sequenceId = 0; diff --git a/UnitTests/CCPackageCocos2dEnablerTests.m b/UnitTests/CCPackageCocos2dEnablerTests.m index f2f22ba6dd0..c9c457b05e3 100644 --- a/UnitTests/CCPackageCocos2dEnablerTests.m +++ b/UnitTests/CCPackageCocos2dEnablerTests.m @@ -11,7 +11,7 @@ #import "CCPackage.h" #import "CCFileUtils.h" #import "CCSprite.h" -#import "CCBReader.h" +#import "CCSBReader.h" #import "AppDelegate.h" #import "CCPackage_private.h" #import "CCPackageHelper.h" diff --git a/UnitTests/CCPhysicsTests.m b/UnitTests/CCPhysicsTests.m index 207f050914b..cf254d70c0a 100644 --- a/UnitTests/CCPhysicsTests.m +++ b/UnitTests/CCPhysicsTests.m @@ -1044,12 +1044,12 @@ -(void)testKineticNodeActionsAdvanced1 [scheduler update:0.10f]; // first tick is always ignored, the action is not run. [scheduler update:0.10f]; // second tick runs the action at time zero, regardless of the delta time. - const float accuracy = 1e-3; +// const float accuracy = 1e-3; //test actions are fixed. for(int i = 0; i < 10; i++) { - float desired = (float)i * 0.1f * 100.0f/10.0f + (float)i * 0.1f * 200.0f/10.0f; - NSLog(@"node1.position.x= %0.2f desired = %0.2f",body1.absolutePosition.x, desired); +// float desired = (float)i * 0.1f * 100.0f/10.0f + (float)i * 0.1f * 200.0f/10.0f; +// NSLog(@"node1.position.x= %0.2f desired = %0.2f",body1.absolutePosition.x, desired); // XCTAssertEqualWithAccuracy(body1.absolutePosition.x, desired, accuracy, @"Not in the right position"); [scheduler update:0.10f]; } diff --git a/UnitTests/CCReaderTest.m b/UnitTests/CCReaderTest.m index 091b9d181b0..204af1f2c3c 100644 --- a/UnitTests/CCReaderTest.m +++ b/UnitTests/CCReaderTest.m @@ -8,7 +8,7 @@ #import #import "cocos2d.h" -#import "CCBReader.h" +#import "CCSBReader.h" #include #include @@ -56,17 +56,17 @@ - (void)setUp -(void)testReaderPerformance { /* - NSString *filePath =[[NSBundle mainBundle] pathsForResourcesOfType:@"ccbi" inDirectory:@"Resources-shared/Tests"][0]; + NSString *filePath =[[NSBundle mainBundle] pathsForResourcesOfType:@"sbi" inDirectory:@"Resources-shared/Tests"][0]; XCTAssertNotNil(filePath); NSData * fileData = [[NSData alloc] initWithContentsOfFile:filePath]; - CCBReader * ccbReader = [[CCBReader alloc] init]; + CCSBReader * CCSBReader = [[CCSBReader alloc] init]; machGetClockDiffS(); for (int i = 0; i < 100; i++) { - [ccbReader loadWithData:fileData owner:self]; + [CCSBReader loadWithData:fileData owner:self]; } NSLog(@"TimeToRun: %0.8f", machGetClockDiffS()); diff --git a/UnitTests/CCTextureTests.m b/UnitTests/CCTextureTests.m index 294dc562b66..eda8dec3b6d 100644 --- a/UnitTests/CCTextureTests.m +++ b/UnitTests/CCTextureTests.m @@ -2,7 +2,7 @@ #import "cocos2d.h" #import "CCTextureCache.h" -#import "CCBReader.h" +#import "CCSBReader.h" #import "AppDelegate.h" @interface CCTextureTests : XCTestCase diff --git a/cocos2d-tests.xcodeproj/project.pbxproj b/cocos2d-tests.xcodeproj/project.pbxproj index 8f4751d5b24..3a38c057a4c 100644 --- a/cocos2d-tests.xcodeproj/project.pbxproj +++ b/cocos2d-tests.xcodeproj/project.pbxproj @@ -31,6 +31,7 @@ 75C72C091A82AD7900814F60 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 75C72C031A82AD6600814F60 /* main.m */; }; 75C72C0A1A82AD7B00814F60 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 75C72C021A82AD6600814F60 /* AppDelegate.m */; }; 75DAC8B11A4240BE003F8244 /* CCImageTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 75DAC8B01A4240BE003F8244 /* CCImageTests.m */; }; + 75DCC9DA1A9285C7003F0592 /* Images in Resources */ = {isa = PBXBuildFile; fileRef = 758A6C6B1843E5C500D1A8D2 /* Images */; }; 75F4EA251A69847C000E637B /* CCActionsTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 75F4EA241A69847C000E637B /* CCActionsTest.m */; }; 75F76497185A831B00E2FAFE /* Sounds in Resources */ = {isa = PBXBuildFile; fileRef = 75F76496185A831B00E2FAFE /* Sounds */; }; 75F9BF5E1A38EE8C009185BF /* CCViewportNodeTest.m in Sources */ = {isa = PBXBuildFile; fileRef = D35C2D261A1BC83F00FF96B0 /* CCViewportNodeTest.m */; }; @@ -383,7 +384,7 @@ 75F76496185A831B00E2FAFE /* Sounds */ = {isa = PBXFileReference; lastKnownFileType = folder; name = Sounds; path = Resources/Sounds; sourceTree = SOURCE_ROOT; }; 830F10971A6D37D50074F583 /* OCMock.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = OCMock.xcodeproj; path = external/OCMock/Source/OCMock.xcodeproj; sourceTree = ""; }; 839B149E19CC1E440000E5E2 /* CCPackageTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCPackageTest.m; path = "cocos2d-ui-tests/tests/CCPackageTest.m"; sourceTree = SOURCE_ROOT; }; - 92324E2918EB635500D78D3F /* CCReaderTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CCReaderTest.m; sourceTree = ""; }; + 92324E2918EB635500D78D3F /* CCReaderTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; lineEnding = 0; path = CCReaderTest.m; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.objc; }; 92FE241018F5F06F00647961 /* CCAnimationTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CCAnimationTest.m; sourceTree = ""; }; 9D96557219D6113500428E79 /* CCEffectTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CCEffectTests.m; sourceTree = ""; }; A6167B92189A7D4D0044D391 /* VertexZTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = VertexZTest.m; path = "cocos2d-ui-tests/tests/VertexZTest.m"; sourceTree = SOURCE_ROOT; }; @@ -532,7 +533,7 @@ E525F98589D25C8CCF99E8B6 /* CCFileLocatorDatabaseTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CCFileLocatorDatabaseTests.m; sourceTree = ""; }; E525F99055258F35DFF00ECD /* CCPackageHelperTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CCPackageHelperTests.m; sourceTree = ""; }; E525FB2B6BB1C2E3BD1457A7 /* CCUnitTestHelperMacros.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCUnitTestHelperMacros.h; sourceTree = ""; }; - E525FB8A3CC89D071A8377B1 /* CCPackageCocos2dEnablerTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CCPackageCocos2dEnablerTests.m; sourceTree = ""; }; + E525FB8A3CC89D071A8377B1 /* CCPackageCocos2dEnablerTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; lineEnding = 0; path = CCPackageCocos2dEnablerTests.m; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.objc; }; E525FBE3FAFA47AD441E6E03 /* FileSystemTestCase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileSystemTestCase.h; sourceTree = ""; }; E525FBF58DFECF27272F5D6F /* CCPackageInstallerTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CCPackageInstallerTests.m; sourceTree = ""; }; E525FCB52B23A4F29E8D6D64 /* CCPackagesTestFixturesAndHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCPackagesTestFixturesAndHelpers.h; sourceTree = ""; }; @@ -1142,6 +1143,7 @@ isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( + 75DCC9DA1A9285C7003F0592 /* Images in Resources */, 9269312A1923D8A700CE6285 /* Resources-shared in Resources */, 75556A1B1856374700ED1B0F /* InfoPlist.strings in Resources */, 75556A15185636FB00ED1B0F /* powered.png in Resources */, diff --git a/cocos2d-ui-tests/ios/AppController.m b/cocos2d-ui-tests/ios/AppController.m index 045d7350e5f..7f380ee0610 100644 --- a/cocos2d-ui-tests/ios/AppController.m +++ b/cocos2d-ui-tests/ios/AppController.m @@ -64,7 +64,7 @@ - (void)configureFileUtilsSearchPathAndRegisterSpriteSheets [[NSUserDefaults standardUserDefaults] synchronize]; // The testbed uses a different directory dictionary than is created by the default CCFileUtils constructor- it uses the file utils one - [CCBReader configureCCFileUtils]; + [CCSBReader configureCCFileUtils]; CCFileUtils* sharedFileUtils = [CCFileUtils sharedFileUtils]; // Testbed needs special directory search paths: diff --git a/cocos2d-ui/CCBReader/CCAnimationManager+FrameAnimation.m b/cocos2d-ui/CCBReader/CCAnimationManager+FrameAnimation.m index 1565bdb49df..b1b7d718e69 100644 --- a/cocos2d-ui/CCBReader/CCAnimationManager+FrameAnimation.m +++ b/cocos2d-ui/CCBReader/CCAnimationManager+FrameAnimation.m @@ -39,7 +39,7 @@ - (void)animationWithSpriteFrames:animFrames delay:(float)delay name:(NSString*) [keyFrames addObject:frameDict]; // Add Animation Sequence - [self addKeyFramesForSequenceNamed:name propertyType:CCBSequencePropertyTypeSpriteFrame frameArray:keyFrames node:node loop:loop]; + [self addKeyFramesForSequenceNamed:name propertyType:CCSequencePropertyTypeSpriteFrame frameArray:keyFrames node:node loop:loop]; } #pragma mark Legacy Animation Support diff --git a/cocos2d-ui/CCBReader/CCAnimationManager.h b/cocos2d-ui/CCBReader/CCAnimationManager.h index 6ad77e88f73..c07fbe4637d 100644 --- a/cocos2d-ui/CCBReader/CCAnimationManager.h +++ b/cocos2d-ui/CCBReader/CCAnimationManager.h @@ -28,7 +28,7 @@ @class CCNode; -@class CCBSequence; +@class CCSequence; #pragma mark Animation Manager Delegate @@ -36,7 +36,7 @@ The animation manager delegate receives callbacks when animation sequences finishes playing. Used by CCAnimationManager. */ -@protocol CCBAnimationManagerDelegate +@protocol CCAnimationManagerDelegate /** * Called when an animation sequence has finished playing. @@ -60,8 +60,8 @@ NSMutableDictionary* _baseValues; NSString *_animationManagerId; - CCBSequence* _runningSequence; - CCBSequence* _lastSequence; + CCSequence* _runningSequence; + CCSequence* _lastSequence; void (^block)(id sender); @@ -130,6 +130,6 @@ /// The animation manager delegate receives updates about the animation playback state. /// @see CCBAnimationManagerDelegate -@property (nonatomic,weak) NSObject* delegate; +@property (nonatomic,weak) NSObject* delegate; @end diff --git a/cocos2d-ui/CCBReader/CCAnimationManager.m b/cocos2d-ui/CCBReader/CCAnimationManager.m index 18d21c24c63..2298f3d1fc5 100644 --- a/cocos2d-ui/CCBReader/CCAnimationManager.m +++ b/cocos2d-ui/CCBReader/CCAnimationManager.m @@ -27,15 +27,15 @@ #import "CCAnimationManager_Private.h" #import "CCDirector_Private.h" -#import "CCBReader_Private.h" +#import "CCSBReader_Private.h" #import "CCScheduler_Private.h" #import "CCAction_Private.h" -#import "CCBKeyframe.h" -#import "CCBSequence.h" -#import "CCBSequenceProperty.h" -#import "CCBReader.h" -#import "CCBKeyframe.h" +#import "CCKeyframe.h" +#import "CCSequence.h" +#import "CCSequenceProperty.h" +#import "CCSBReader.h" +#import "CCKeyframe.h" #import "OALSimpleAudio.h" #import "CCActionInterval.h" #import "CCActionInstant.h" @@ -49,7 +49,7 @@ static NSInteger ccbAnimationManagerID = 0; -@interface CCBActionTweenColor : CCActionInterval { +@interface CCActionTweenColor : CCActionInterval { NSString *_key; CCColor *_to; CCColor *_from; @@ -117,11 +117,11 @@ - (void)addNode:(CCNode*)node andSequences:(NSDictionary*)seq for (NSMutableDictionary* seqNodeProps in seq.allValues) { - for (CCBSequenceProperty* seqProp in seqNodeProps.allValues) + for (CCSequenceProperty* seqProp in seqNodeProps.allValues) { if(seqProp.keyframes.count > 0) { - CCBKeyframe * keyFrameZero = seqProp.keyframes[0]; + CCKeyframe * keyFrameZero = seqProp.keyframes[0]; NSAssert(keyFrameZero.time == 0.0f, @"The first keyframe should always be at time Zero."); } @@ -178,7 +178,7 @@ - (id)baseValueForNode:(CCNode*) node propertyName:(NSString*) propName { } - (int)sequenceIdForSequenceNamed:(NSString*)name { - for (CCBSequence* seq in _sequences) { + for (CCSequence* seq in _sequences) { if ([seq.name isEqualToString:name]) { return seq.sequenceId; } @@ -187,18 +187,18 @@ - (int)sequenceIdForSequenceNamed:(NSString*)name { return -1; } -- (CCBSequence*)sequenceFromSequenceId:(int)seqId { - for (CCBSequence* seq in _sequences) +- (CCSequence*)sequenceFromSequenceId:(int)seqId { + for (CCSequence* seq in _sequences) { if (seq.sequenceId == seqId) return seq; } return NULL; } -- (CCAction*)actionFromKeyframe0:(CCBKeyframe*)kf0 andKeyframe1:(CCBKeyframe*)kf1 propertyName:(NSString*)name node:(CCNode*)node { +- (CCAction*)actionFromKeyframe0:(CCKeyframe*)kf0 andKeyframe1:(CCKeyframe*)kf1 propertyName:(NSString*)name node:(CCNode*)node { float duration = kf1.time - kf0.time; - if(kf0 && kf0.easingType==kCCBKeyframeEasingInstant) { + if(kf0 && kf0.easingType==kCCKeyframeEasingInstant) { duration = 0; } @@ -258,10 +258,10 @@ - (CCAction*)actionFromKeyframe0:(CCBKeyframe*)kf0 andKeyframe1:(CCBKeyframe*)kf } else if ([name isEqualToString:@"specularColor"] || [name isEqualToString:@"ambientColor"]) { - return [CCBActionTweenColor actionWithDuration:duration key:name from:kf0.value to:kf1.value]; + return [CCActionTweenColor actionWithDuration:duration key:name from:kf0.value to:kf1.value]; } } else { - CCLOG(@"CCBReader: Failed to create animation for property: %@", name); + CCLOG(@"CCSBReader: Failed to create animation for property: %@", name); } return NULL; @@ -270,10 +270,10 @@ - (CCAction*)actionFromKeyframe0:(CCBKeyframe*)kf0 andKeyframe1:(CCBKeyframe*)kf - (void)setAnimatedProperty:(NSString*)name forNode:(CCNode*)node toValue:(id)value tweenDuration:(float) tweenDuration { if (tweenDuration > 0) { // Create a fake keyframe to generate the action from - CCBKeyframe* kf1 = [[CCBKeyframe alloc] init]; + CCKeyframe* kf1 = [[CCKeyframe alloc] init]; kf1.value = value; kf1.time = tweenDuration; - kf1.easingType = kCCBKeyframeEasingLinear; + kf1.easingType = kCCKeyframeEasingLinear; CCAction* tweenAction = [self actionFromKeyframe0:NULL andKeyframe1:kf1 propertyName:name node:node]; tweenAction.name = _animationManagerId; @@ -311,7 +311,7 @@ - (void)setAnimatedProperty:(NSString*)name forNode:(CCNode*)node toValue:(id)va } } -- (void)setKeyFrameForNode:(CCNode*)node sequenceProperty:(CCBSequenceProperty*)seqProp tweenDuration:(float)tweenDuration keyFrame:(int)kf { +- (void)setKeyFrameForNode:(CCNode*)node sequenceProperty:(CCSequenceProperty*)seqProp tweenDuration:(float)tweenDuration keyFrame:(int)kf { NSArray* keyframes = [seqProp keyframes]; if ([keyframes count] == 0) { @@ -321,7 +321,7 @@ - (void)setKeyFrameForNode:(CCNode*)node sequenceProperty:(CCBSequenceProperty*) [self setAnimatedProperty:seqProp.name forNode:node toValue:baseValue tweenDuration:tweenDuration]; } else { // Use Specified KeyFrame - CCBKeyframe* keyframe = [keyframes objectAtIndex:kf]; + CCKeyframe* keyframe = [keyframes objectAtIndex:kf]; [self setAnimatedProperty:seqProp.name forNode:node toValue:keyframe.value tweenDuration:tweenDuration]; } } @@ -333,74 +333,74 @@ - (CCAction*)easeAction:(CCAction*) action easingType:(int)easingType easingOpt: CCActionInterval*intervalAction = (CCActionInterval*)action; if(!intervalAction) { - NSLog(@"CCBReader: Incorrect action type %@ for easing - must be a CCActionInterval subclass", action); + NSLog(@"CCSBReader: Incorrect action type %@ for easing - must be a CCActionInterval subclass", action); return nil; } - if (easingType == kCCBKeyframeEasingLinear) + if (easingType == kCCKeyframeEasingLinear) { return action; } - else if (easingType == kCCBKeyframeEasingInstant) + else if (easingType == kCCKeyframeEasingInstant) { return [CCActionEaseInstant actionWithAction:intervalAction]; } - else if (easingType == kCCBKeyframeEasingCubicIn) + else if (easingType == kCCKeyframeEasingCubicIn) { return [CCActionEaseIn actionWithAction:intervalAction rate:easingOpt]; } - else if (easingType == kCCBKeyframeEasingCubicOut) + else if (easingType == kCCKeyframeEasingCubicOut) { return [CCActionEaseOut actionWithAction:intervalAction rate:easingOpt]; } - else if (easingType == kCCBKeyframeEasingCubicInOut) + else if (easingType == kCCKeyframeEasingCubicInOut) { return [CCActionEaseInOut actionWithAction:intervalAction rate:easingOpt]; } - else if (easingType == kCCBKeyframeEasingBackIn) + else if (easingType == kCCKeyframeEasingBackIn) { return [CCActionEaseBackIn actionWithAction:intervalAction]; } - else if (easingType == kCCBKeyframeEasingBackOut) + else if (easingType == kCCKeyframeEasingBackOut) { return [CCActionEaseBackOut actionWithAction:intervalAction]; } - else if (easingType == kCCBKeyframeEasingBackInOut) + else if (easingType == kCCKeyframeEasingBackInOut) { return [CCActionEaseBackInOut actionWithAction:intervalAction]; } - else if (easingType == kCCBKeyframeEasingBounceIn) + else if (easingType == kCCKeyframeEasingBounceIn) { return [CCActionEaseBounceIn actionWithAction:intervalAction]; } - else if (easingType == kCCBKeyframeEasingBounceOut) + else if (easingType == kCCKeyframeEasingBounceOut) { return [CCActionEaseBounceOut actionWithAction:intervalAction]; } - else if (easingType == kCCBKeyframeEasingBounceInOut) + else if (easingType == kCCKeyframeEasingBounceInOut) { return [CCActionEaseBounceInOut actionWithAction:intervalAction]; } - else if (easingType == kCCBKeyframeEasingElasticIn) + else if (easingType == kCCKeyframeEasingElasticIn) { return [CCActionEaseElasticIn actionWithAction:intervalAction period:easingOpt]; } - else if (easingType == kCCBKeyframeEasingElasticOut) + else if (easingType == kCCKeyframeEasingElasticOut) { return [CCActionEaseElasticOut actionWithAction:intervalAction period:easingOpt]; } - else if (easingType == kCCBKeyframeEasingElasticInOut) + else if (easingType == kCCKeyframeEasingElasticInOut) { return [CCActionEaseElasticInOut actionWithAction:intervalAction period:easingOpt]; } else { - NSLog(@"CCBReader: Unkown easing type %d", easingType); + NSLog(@"CCSBReader: Unkown easing type %d", easingType); return action; } } -- (void)runActionsForNode:(CCNode*)node sequenceProperty:(CCBSequenceProperty*)seqProp tweenDuration:(float)tweenDuration startKeyFrame:(int)startFrame { +- (void)runActionsForNode:(CCNode*)node sequenceProperty:(CCSequenceProperty*)seqProp tweenDuration:(float)tweenDuration startKeyFrame:(int)startFrame { // Grab Key Frames / Count NSArray* keyframes = [seqProp keyframes]; @@ -417,7 +417,7 @@ - (void)runActionsForNode:(CCNode*)node sequenceProperty:(CCBSequenceProperty*)s return; // First Frame - CCBKeyframe* kf0 = [keyframes objectAtIndex:startFrame]; + CCKeyframe* kf0 = [keyframes objectAtIndex:startFrame]; // Initial Tween Required if(startFrame==0) { @@ -452,12 +452,12 @@ - (void)runActionsForNode:(CCNode*)node sequenceProperty:(CCBSequenceProperty*)s [_currentActions addObject:seq]; } -- (id)actionForCallbackChannel:(CCBSequenceProperty*) channel { +- (id)actionForCallbackChannel:(CCSequenceProperty*) channel { float lastKeyframeTime = 0; NSMutableArray* actions = [NSMutableArray array]; - for (CCBKeyframe* keyframe in channel.keyframes) { + for (CCKeyframe* keyframe in channel.keyframes) { float timeSinceLastKeyframe = keyframe.time - lastKeyframeTime; lastKeyframeTime = keyframe.time; @@ -470,8 +470,8 @@ - (id)actionForCallbackChannel:(CCBSequenceProperty*) channel { // Callback through obj-c id target = NULL; - if (selectorTarget == kCCBTargetTypeDocumentRoot) target = self.rootNode; - else if (selectorTarget == kCCBTargetTypeOwner) target = _owner; + if (selectorTarget == kCCTargetTypeDocumentRoot) target = self.rootNode; + else if (selectorTarget == kCCTargetTypeOwner) target = _owner; SEL selector = NSSelectorFromString(selectorName); @@ -485,13 +485,13 @@ - (id)actionForCallbackChannel:(CCBSequenceProperty*) channel { return [CCActionSequence actionWithArray:actions]; } -- (id)actionForSoundChannel:(CCBSequenceProperty*) channel { +- (id)actionForSoundChannel:(CCSequenceProperty*) channel { float lastKeyframeTime = 0; NSMutableArray* actions = [NSMutableArray array]; - for (CCBKeyframe* keyframe in channel.keyframes) { + for (CCKeyframe* keyframe in channel.keyframes) { float timeSinceLastKeyframe = keyframe.time - lastKeyframeTime; lastKeyframeTime = keyframe.time; @@ -538,7 +538,7 @@ - (void)runAnimationsForSequenceId:(int)seqId tweenDuration:(float) tweenDuratio // Reset nodes that have sequence node properties, build first keyframe action sequence. for (NSString* propName in seqNodeProps) { - CCBSequenceProperty* seqProp = [seqNodeProps objectForKey:propName]; + CCSequenceProperty* seqProp = [seqNodeProps objectForKey:propName]; [seqNodePropNames addObject:propName]; // Reset Node State to First KeyFrame @@ -579,7 +579,7 @@ - (void)runAnimationsForSequenceNamed:(NSString*)name { - (void)addSequenceCallBacks:(int)seqId tweenDuration:(float)tweenDuration startTime:(float)time { // End of Sequence Callback - CCBSequence* seq = [self sequenceFromSequenceId:seqId]; + CCSequence* seq = [self sequenceFromSequenceId:seqId]; CCActionSequence* completeAction = [CCActionSequence actionOne:[CCActionDelay actionWithDuration:seq.duration+tweenDuration-time] @@ -703,7 +703,7 @@ - (void)timeSeekStaticForSequenceId:(int)seqId time:(float)time { } for (NSString* propName in seqNodeProps) { - CCBSequenceProperty* seqProp = [seqNodeProps objectForKey:propName]; + CCSequenceProperty* seqProp = [seqNodeProps objectForKey:propName]; NSMutableArray* keyFrames = [self findFrames:time sequenceProperty:seqProp]; // No KeyFrames Found @@ -720,7 +720,7 @@ - (void)timeSeekStaticForSequenceId:(int)seqId time:(float)time { // Set Initial State First Key Frame [self setKeyFrameForNode:node sequenceProperty:seqProp tweenDuration:0 keyFrame:[[keyFrames objectAtIndex:0] intValue]]; - CCBKeyframe* currentKeyFrame = [seqProp.keyframes objectAtIndex:[[keyFrames objectAtIndex:0] unsignedIntegerValue]]; + CCKeyframe* currentKeyFrame = [seqProp.keyframes objectAtIndex:[[keyFrames objectAtIndex:0] unsignedIntegerValue]]; float timeFoward = time - currentKeyFrame.time; @@ -779,7 +779,7 @@ - (void) timeSeekForSequenceId:(int)seqId time:(float)time { } for (NSString* propName in seqNodeProps) { - CCBSequenceProperty* seqProp = [seqNodeProps objectForKey:propName]; + CCSequenceProperty* seqProp = [seqNodeProps objectForKey:propName]; NSMutableArray* keyFrames = [self findFrames:time sequenceProperty:seqProp]; // No KeyFrames Found @@ -796,7 +796,7 @@ - (void) timeSeekForSequenceId:(int)seqId time:(float)time { // Set Initial State First Key Frame [self setKeyFrameForNode:node sequenceProperty:seqProp tweenDuration:0 keyFrame:[[keyFrames objectAtIndex:0] intValue]]; - CCBKeyframe* currentKeyFrame = [seqProp.keyframes objectAtIndex:[[keyFrames objectAtIndex:0] unsignedIntegerValue]]; + CCKeyframe* currentKeyFrame = [seqProp.keyframes objectAtIndex:[[keyFrames objectAtIndex:0] unsignedIntegerValue]]; float timeFoward = time - currentKeyFrame.time; @@ -832,18 +832,18 @@ - (void) timeSeekForSequenceId:(int)seqId time:(float)time { _runningSequence.time = time; } -- (NSMutableArray*)findFrames:(float)time sequenceProperty:(CCBSequenceProperty*) seqProp{ +- (NSMutableArray*)findFrames:(float)time sequenceProperty:(CCSequenceProperty*) seqProp{ NSMutableArray* result = [[NSMutableArray alloc] init]; - CCBKeyframe* startKeyFrame = [seqProp.keyframes objectAtIndex:0]; - CCBKeyframe* endKeyFrame = [seqProp.keyframes objectAtIndex:0]; + CCKeyframe* startKeyFrame = [seqProp.keyframes objectAtIndex:0]; + CCKeyframe* endKeyFrame = [seqProp.keyframes objectAtIndex:0]; NSUInteger frameCount = [seqProp.keyframes count]; // Find KeyFrames int i; for (i = 0; i < frameCount; i++) { - CCBKeyframe* currentKey = [seqProp.keyframes objectAtIndex:i]; + CCKeyframe* currentKey = [seqProp.keyframes objectAtIndex:i]; if (currentKey.time>time) { endKeyFrame = currentKey; @@ -864,12 +864,12 @@ - (NSMutableArray*)findFrames:(float)time sequenceProperty:(CCBSequenceProperty* return result; } -- (CCActionSequence*)createActionForNode:(CCNode*)node sequenceProperty:(CCBSequenceProperty*)seqProp beginKeyFrame:(int)beginKeyFrame endKeyFrame:(int)endKeyFrame +- (CCActionSequence*)createActionForNode:(CCNode*)node sequenceProperty:(CCSequenceProperty*)seqProp beginKeyFrame:(int)beginKeyFrame endKeyFrame:(int)endKeyFrame { NSArray* keyframes = [seqProp keyframes]; - CCBKeyframe* startKF = [keyframes objectAtIndex:beginKeyFrame]; - CCBKeyframe* endKF = [keyframes objectAtIndex:endKeyFrame]; + CCKeyframe* startKF = [keyframes objectAtIndex:beginKeyFrame]; + CCKeyframe* endKF = [keyframes objectAtIndex:endKeyFrame]; CCActionSequence* seq = nil; @@ -881,7 +881,7 @@ - (CCActionSequence*)createActionForNode:(CCNode*)node sequenceProperty:(CCBSequ if (action) { // Instant - if(startKF.easingType==kCCBKeyframeEasingInstant) { + if(startKF.easingType==kCCKeyframeEasingInstant) { [actions addObject:[CCActionDelay actionWithDuration:endKF.time-startKF.time]]; } @@ -953,12 +953,12 @@ - (void)clearAllActions { #pragma mark Simple Sequence Builder -- (void)addKeyFramesForSequenceNamed:(NSString*)name propertyType:(CCBSequencePropertyType)propertyType frameArray:(NSArray*)frameArray node:(CCNode *)node loop:(BOOL)loop { +- (void)addKeyFramesForSequenceNamed:(NSString*)name propertyType:(CCSequencePropertyType)propertyType frameArray:(NSArray*)frameArray node:(CCNode *)node loop:(BOOL)loop { int seqId = (int)[self.sequences count]; // Create New Sequence - CCBSequence* sequence = [[CCBSequence alloc] init]; + CCSequence* sequence = [[CCSequence alloc] init]; [sequence setName:name]; [sequence setSequenceId:seqId]; [self.sequences addObject:sequence]; @@ -968,11 +968,11 @@ - (void)addKeyFramesForSequenceNamed:(NSString*)name propertyType:(CCBSequencePr [sequence setChainedSequenceId:seqId]; } - NSString *propertyName = [CCBSequenceProperty getPropertyNameFromTypeId:propertyType]; + NSString *propertyName = [CCSequenceProperty getPropertyNameFromTypeId:propertyType]; NSAssert(propertyName != nil, @"Property type %d couldn't be found",(int)propertyType); // Create Sequence Property - CCBSequenceProperty* sequenceProperty = [[CCBSequenceProperty alloc] init]; + CCSequenceProperty* sequenceProperty = [[CCSequenceProperty alloc] init]; [sequenceProperty setName:propertyName]; [sequenceProperty setType:propertyType]; @@ -982,7 +982,7 @@ - (void)addKeyFramesForSequenceNamed:(NSString*)name propertyType:(CCBSequencePr for(NSDictionary* frameDict in frameArray) { // Create KeyFrame - CCBKeyframe* newFrame = [[CCBKeyframe alloc] init]; + CCKeyframe* newFrame = [[CCKeyframe alloc] init]; [newFrame setTime:[[frameDict valueForKey:@"time"] floatValue]]; [newFrame setValue:[CCSpriteFrame frameWithImageNamed:[frameDict objectForKey:@"value"]]]; @@ -1011,10 +1011,10 @@ - (void)addKeyFramesForSequenceNamed:(NSString*)name propertyType:(CCBSequencePr @end -@implementation CCBActionTweenColor +@implementation CCActionTweenColor + (id)actionWithDuration:(CCTime)duration key:(NSString *)key from:(CCColor*)fc to:(CCColor*)tc; { - return [(CCBActionTweenColor*)[ self alloc] initWithDuration:duration key:key from:fc to:tc]; + return [(CCActionTweenColor*)[ self alloc] initWithDuration:duration key:key from:fc to:tc]; } - (id)initWithDuration:(CCTime)duration key:(NSString *)key from:(CCColor*)fc to:(CCColor*)tc; @@ -1030,7 +1030,7 @@ - (id)initWithDuration:(CCTime)duration key:(NSString *)key from:(CCColor*)fc to -(id) copyWithZone: (NSZone*) zone { - CCAction *copy = [(CCBActionTweenColor*)[[self class] allocWithZone: zone] initWithDuration:[self duration] key:_key from:_from to:_to]; + CCAction *copy = [(CCActionTweenColor*)[[self class] allocWithZone: zone] initWithDuration:[self duration] key:_key from:_from to:_to]; return copy; } diff --git a/cocos2d-ui/CCBReader/CCAnimationManager_Private.h b/cocos2d-ui/CCBReader/CCAnimationManager_Private.h index 8a85a3217e8..db5aafde480 100644 --- a/cocos2d-ui/CCBReader/CCAnimationManager_Private.h +++ b/cocos2d-ui/CCBReader/CCAnimationManager_Private.h @@ -24,7 +24,7 @@ #import "CCAnimationManager.h" -#import "CCBSequenceProperty.h" +#import "CCSequenceProperty.h" @interface CCAnimationManager () @@ -39,13 +39,13 @@ // Base node. @property (nonatomic,unsafe_unretained) CCNode* rootNode; -// (CCB) Optional owner +// Optional owner @property (nonatomic,unsafe_unretained) id owner; -// (CCB) Resolution and default container size. +// Resolution and default container size. @property (nonatomic,assign) CGSize rootContainerSize; -// (CCB) Node Management +// Node Management - (CGSize) containerSize:(CCNode*)node; - (void) addNode:(CCNode*)node andSequences:(NSDictionary*)seq; - (void) moveAnimationsFromNode:(CCNode*)fromNode toNode:(CCNode*)toNode; @@ -58,7 +58,7 @@ - (void)timeSeekForSequenceId:(int)seqId time:(float)time; #pragma mark Simple Sequence Builder -- (void)addKeyFramesForSequenceNamed:(NSString*)name propertyType:(CCBSequencePropertyType)propertyType frameArray:(NSArray*)frameArray node:(CCNode *)node loop:(BOOL)loop; +- (void)addKeyFramesForSequenceNamed:(NSString*)name propertyType:(CCSequencePropertyType)propertyType frameArray:(NSArray*)frameArray node:(CCNode *)node loop:(BOOL)loop; @end diff --git a/cocos2d-ui/CCBReader/CCBAnimationManager.h b/cocos2d-ui/CCBReader/CCBAnimationManager.h deleted file mode 100644 index 3ceb2656ca7..00000000000 --- a/cocos2d-ui/CCBReader/CCBAnimationManager.h +++ /dev/null @@ -1,36 +0,0 @@ -/* - * SpriteBuilder: http://www.spritebuilder.org - * - * Copyright (c) 2012 Zynga Inc. - * Copyright (c) 2013 Apportable Inc. - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - * THE SOFTWARE. - */ - -#import -#import "CCAnimationManager.h" - -//This has been replaced by CCAnimationManager -__attribute__ ((deprecated)) -@interface CCBAnimationManager : CCAnimationManager -{ - -} - -@end diff --git a/cocos2d-ui/CCBReader/CCBAnimationManager.m b/cocos2d-ui/CCBReader/CCBAnimationManager.m deleted file mode 100644 index 96b16b62a79..00000000000 --- a/cocos2d-ui/CCBReader/CCBAnimationManager.m +++ /dev/null @@ -1,31 +0,0 @@ -/* - * SpriteBuilder: http://www.spritebuilder.org - * - * Copyright (c) 2012 Zynga Inc. - * Copyright (c) 2013 Apportable Inc. - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - * THE SOFTWARE. - */ - -#import "CCBAnimationManager.h" - -@implementation CCBAnimationManager - - -@end diff --git a/cocos2d-ui/CCBReader/CCBReader_Private.h b/cocos2d-ui/CCBReader/CCBReader_Private.h deleted file mode 100644 index 2ce1ce3a427..00000000000 --- a/cocos2d-ui/CCBReader/CCBReader_Private.h +++ /dev/null @@ -1,91 +0,0 @@ -// -// CCBReader_Private.h -// cocos2d-ios -// -// Created by Viktor on 11/13/13. -// -// - -#import "CCBReader.h" - -#define kCCBVersion 11 - -enum { - kCCBPropTypePosition = 0, - kCCBPropTypeSize, - kCCBPropTypePoint, - kCCBPropTypePointLock, - kCCBPropTypeScaleLock, - kCCBPropTypeDegrees, - kCCBPropTypeInteger, - kCCBPropTypeFloat, - kCCBPropTypeFloatVar, - kCCBPropTypeCheck, - kCCBPropTypeSpriteFrame, - kCCBPropTypeTexture, - kCCBPropTypeByte, - kCCBPropTypeColor3, - kCCBPropTypeColor4FVar, - kCCBPropTypeFlip, - kCCBPropTypeBlendmode, - kCCBPropTypeFntFile, - kCCBPropTypeText, - kCCBPropTypeFontTTF, - kCCBPropTypeIntegerLabeled, - kCCBPropTypeBlock, - kCCBPropTypeAnimation, - kCCBPropTypeCCBFile, - kCCBPropTypeString, - kCCBPropTypeBlockCCControl, - kCCBPropTypeFloatScale, - kCCBPropTypeFloatXY, - kCCBPropTypeColor4, - kCCBPropTypeNodeReference, - kCCBPropTypeFloatCheck, - kCCBPropTypeEffects, - kCCBPropTypeTokenArray -}; - -enum { - kCCBFloat0 = 0, - kCCBFloat1, - kCCBFloatMinus1, - kCCBFloat05, - kCCBFloatInteger, - kCCBFloatFull -}; - -enum { - kCCBPlatformAll = 0, - kCCBPlatformIOS, - kCCBPlatformMac -}; - -enum { - kCCBTargetTypeNone = 0, - kCCBTargetTypeDocumentRoot = 1, - kCCBTargetTypeOwner = 2, -}; - -enum -{ - kCCBKeyframeEasingInstant, - - kCCBKeyframeEasingLinear, - - kCCBKeyframeEasingCubicIn, - kCCBKeyframeEasingCubicOut, - kCCBKeyframeEasingCubicInOut, - - kCCBKeyframeEasingElasticIn, - kCCBKeyframeEasingElasticOut, - kCCBKeyframeEasingElasticInOut, - - kCCBKeyframeEasingBounceIn, - kCCBKeyframeEasingBounceOut, - kCCBKeyframeEasingBounceInOut, - - kCCBKeyframeEasingBackIn, - kCCBKeyframeEasingBackOut, - kCCBKeyframeEasingBackInOut, -}; diff --git a/cocos2d-ui/CCBReader/CCBuilderReader.h b/cocos2d-ui/CCBReader/CCBuilderReader.h index a3690dce53a..ea7c049879a 100644 --- a/cocos2d-ui/CCBReader/CCBuilderReader.h +++ b/cocos2d-ui/CCBReader/CCBuilderReader.h @@ -23,7 +23,6 @@ * THE SOFTWARE. */ -#import "CCBReader.h" -#import "CCBAnimationManager.h" +#import "CCSBReader.h" #import "CCAnimationManager.h" -#import "CCBLocalizationManager.h" +#import "CCLocalizationManager.h" diff --git a/cocos2d-ui/CCBReader/CCBKeyframe.h b/cocos2d-ui/CCBReader/CCKeyframe.h similarity index 96% rename from cocos2d-ui/CCBReader/CCBKeyframe.h rename to cocos2d-ui/CCBReader/CCKeyframe.h index b4f38fe913b..9ce7c9c2c62 100644 --- a/cocos2d-ui/CCBReader/CCBKeyframe.h +++ b/cocos2d-ui/CCBReader/CCKeyframe.h @@ -27,7 +27,7 @@ @class CCActionSequence; -@interface CCBKeyframe : NSObject +@interface CCKeyframe : NSObject @property (nonatomic,strong) id value; @property (nonatomic,assign) float time; diff --git a/cocos2d-ui/CCBReader/CCBKeyframe.m b/cocos2d-ui/CCBReader/CCKeyframe.m similarity index 94% rename from cocos2d-ui/CCBReader/CCBKeyframe.m rename to cocos2d-ui/CCBReader/CCKeyframe.m index 522ea290628..52313da03f5 100644 --- a/cocos2d-ui/CCBReader/CCBKeyframe.m +++ b/cocos2d-ui/CCBReader/CCKeyframe.m @@ -23,9 +23,9 @@ * THE SOFTWARE. */ -#import "CCBKeyframe.h" +#import "CCKeyframe.h" -@implementation CCBKeyframe +@implementation CCKeyframe - (id)init { @@ -50,7 +50,7 @@ - (NSString *) description { - (id)copyWithZone:(NSZone *)zone { - CCBKeyframe * copyKeyframe = [[self class] allocWithZone:zone]; + CCKeyframe * copyKeyframe = [[self class] allocWithZone:zone]; copyKeyframe->_value = self->_value; copyKeyframe->_time = self->_time; copyKeyframe->_easingType = self->_easingType; diff --git a/cocos2d-ui/CCBReader/CCBLocalizationManager.h b/cocos2d-ui/CCBReader/CCLocalizationManager.h similarity index 92% rename from cocos2d-ui/CCBReader/CCBLocalizationManager.h rename to cocos2d-ui/CCBReader/CCLocalizationManager.h index 1ac8feae586..e187799eec4 100644 --- a/cocos2d-ui/CCBReader/CCBLocalizationManager.h +++ b/cocos2d-ui/CCBReader/CCLocalizationManager.h @@ -25,9 +25,9 @@ #import #define CCBLocalize(key) \ -[[CCBLocalizationManager sharedManager] localizedStringForKey:(key)] +[[CCLocalizationManager sharedManager] localizedStringForKey:(key)] -@interface CCBLocalizationManager : NSObject +@interface CCLocalizationManager : NSObject { NSMutableDictionary* _translations; } diff --git a/cocos2d-ui/CCBReader/CCBLocalizationManager.m b/cocos2d-ui/CCBReader/CCLocalizationManager.m similarity index 94% rename from cocos2d-ui/CCBReader/CCBLocalizationManager.m rename to cocos2d-ui/CCBReader/CCLocalizationManager.m index 287d003cf7f..b60d54e65f3 100644 --- a/cocos2d-ui/CCBReader/CCBLocalizationManager.m +++ b/cocos2d-ui/CCBReader/CCLocalizationManager.m @@ -22,18 +22,18 @@ * THE SOFTWARE. */ -#import "CCBLocalizationManager.h" -#import "CCBReader.h" +#import "CCLocalizationManager.h" +#import "CCSBReader.h" #import "CCFileUtils.h" -@implementation CCBLocalizationManager +@implementation CCLocalizationManager @synthesize translations = _translations; + (id)sharedManager { static dispatch_once_t pred; - static CCBLocalizationManager *loc = nil; + static CCLocalizationManager *loc = nil; dispatch_once(&pred, ^{ loc = [[self alloc] init]; }); @@ -45,7 +45,7 @@ - (id) init self = [super init]; if (!self) return NULL; - [self loadStringsFile:@"Strings.ccbLang"]; + [self loadStringsFile:@"Strings.sbLang"]; return self; } diff --git a/cocos2d-ui/CCBReader/CCBReader.h b/cocos2d-ui/CCBReader/CCSBReader.h similarity index 67% rename from cocos2d-ui/CCBReader/CCBReader.h rename to cocos2d-ui/CCBReader/CCSBReader.h index a3b13b08e1e..77860821c5d 100644 --- a/cocos2d-ui/CCBReader/CCBReader.h +++ b/cocos2d-ui/CCBReader/CCSBReader.h @@ -29,40 +29,50 @@ #import "CCSpriteFrame.h" #import "CCAnimationManager.h" +@protocol CCSBReaderDidLoad +@optional +- (void) didLoadFromSB; + +@end + +@interface CCNode(CCSBReader) + +@end + /** - The CCBReader loads SpriteBuilder (CCB) documents. + The CCSBReader loads SpriteBuilder (SB) documents. For the most part you'll just use one of these two methods: - // load a CCB document as a CCNode instance - CCNode* myNode = [CCBReader load:@"MyNode"]; + // load a SB document as a CCNode instance + CCNode* myNode = [CCSBReader load:@"MyNode"]; - // load a CCB document of type "Sprite" as a CCSprite instance - CCSprite* mySprite = (CCSprite*)[CCBReader load:@"MySprite"]; + // load a SB document of type "Sprite" as a CCSprite instance + CCSprite* mySprite = (CCSprite*)[CCSBReader load:@"MySprite"]; - // load a CCB document wrapped in a CCScene instance - CCScene* scene = [CCBReader loadAsScene:@"MyNode"]; + // load a SB document wrapped in a CCScene instance + CCScene* scene = [CCSBReader loadAsScene:@"MyNode"]; - You can optionally pass an owner object to the CCBReader load methods. This owner object then gets assigned all of the SpriteBuilder document's member variables that are marked to be set to the "Owner". + You can optionally pass an owner object to the CCSBReader load methods. This owner object then gets assigned all of the SpriteBuilder document's member variables that are marked to be set to the "Owner". In all other cases owner is nil and assigning variables to Owner discards their assignment. - When a SpriteBuilder document was loaded, all nodes created from the document will receive the didLoadFromCCB message, if implemented as follows: + When a SpriteBuilder document was loaded, all nodes created from the document will receive the didLoadFromSB message, if implemented as follows: **Objective-C:** - -(void) didLoadFromCCB { + -(void) didLoadFromSB { NSLog(@"%@ did load", self); } **Swift:** - func didLoadFromCCB() { + func didLoadFromSB() { NSLog("%@ did load", self) } Nodes created from a SpriteBuilder document will also have a valid CCAnimationManager instance assigned to their [CCNode animationManager] property. */ -@interface CCBReader : NSObject +@interface CCSBReader : NSObject { NSData* data; unsigned char* bytes; @@ -95,18 +105,18 @@ /// ----------------------------------------------------------------------- /** - * Creates a new CCBReader. You don't normally need to do this because you can directly use most methods, ie `[CCBReader load:@"MyNode"];`. + * Creates a new CCSBReader. You don't normally need to do this because you can directly use most methods, ie `[CCSBReader load:@"MyNode"];`. * - * @return A new CCBReader. + * @return A new CCSBReader. */ -+ (CCBReader*) reader; ++ (CCSBReader*) reader; /// ----------------------------------------------------------------------- /// @name Loading SpriteBuilder documents /// ----------------------------------------------------------------------- /** - * Loads a ccbi-file with the specified name. Using the extension is optional, e.g. both MyNodeGraph and MyNodeGraph.ccbi will work. + * Loads a sbi-file with the specified name. Using the extension is optional, e.g. both MyNodeGraph and MyNodeGraph.sbi will work. * * @param file Name of the file to load. * @@ -115,7 +125,7 @@ - (CCNode*) load:(NSString*) file; /** - * Loads a ccbi-file with the specified name. Using the extension is optional, e.g. both MyNodeGraph and MyNodeGraph.ccbi will work. + * Loads a sbi-file with the specified name. Using the extension is optional, e.g. both MyNodeGraph and MyNodeGraph.sbi will work. * * @param file Name of the file to load. * @@ -124,7 +134,7 @@ + (CCNode*) load:(NSString*) file; /** - * Loads a ccbi-file with the specified name and wraps it in a CCScene node. Using the extension is optional, e.g. both MyNodeGraph and MyNodeGraph.ccbi will work. + * Loads a sbi-file with the specified name and wraps it in a CCScene node. Using the extension is optional, e.g. both MyNodeGraph and MyNodeGraph.sbi will work. * * @param file Name of the file to load. * @@ -137,7 +147,7 @@ /// ----------------------------------------------------------------------- /** - * Loads a ccbi-file with the specified name and owner. Using the extension is optional, e.g. both MyNodeGraph and MyNodeGraph.ccbi will work. + * Loads a sbi-file with the specified name and owner. Using the extension is optional, e.g. both MyNodeGraph and MyNodeGraph.sbi will work. * * @param file Name of the file to load. * @param owner The owner object used to load the file. @@ -147,9 +157,9 @@ - (CCNode*) load:(NSString*) file owner:(id)owner; /** - * Loads a ccbi-file from the provided NSData object. This method is useful if you load ccbi-files from the internet. If you are not using the owner variable, pass NULL. + * Loads a sbi-file from the provided NSData object. This method is useful if you load sbi-files from the internet. If you are not using the owner variable, pass NULL. * - * @param data Data object to load the ccbi-file from. + * @param data Data object to load the sbi-file from. * @param owner The owner object used to load the file, or NULL if not used. * * @return The loaded node graph. @@ -157,7 +167,7 @@ - (CCNode*) loadWithData:(NSData*) data owner:(id)owner; /** - * Loads a ccbi-file with the specified name and owner. Using the extension is optional, e.g. both MyNodeGraph and MyNodeGraph.ccbi will work. + * Loads a sbi-file with the specified name and owner. Using the extension is optional, e.g. both MyNodeGraph and MyNodeGraph.sbi will work. * * @param file Name of the file to load. * @param owner The owner object used to load the file. @@ -167,7 +177,7 @@ + (CCNode*) load:(NSString*) file owner:(id)owner; /** - * Loads a ccbi-file with the specified name and owner and wraps it in a CCScene node. Using the extension is optional, e.g. both MyNodeGraph and MyNodeGraph.ccbi will work. + * Loads a sbi-file with the specified name and owner and wraps it in a CCScene node. Using the extension is optional, e.g. both MyNodeGraph and MyNodeGraph.sbi will work. * * @param file Name of the file to load. * @param owner The owner object used to load the file. @@ -181,8 +191,9 @@ /// ----------------------------------------------------------------------- /** - * Once a ccb-file has been loaded, the animationManager property will be set to contain the top level CCAnimationManager + * Once a sb-file has been loaded, the animationManager property will be set to contain the top level CCAnimationManager */ @property (nonatomic,strong) CCAnimationManager* animationManager; @end + diff --git a/cocos2d-ui/CCBReader/CCBReader.m b/cocos2d-ui/CCBReader/CCSBReader.m similarity index 89% rename from cocos2d-ui/CCBReader/CCBReader.m rename to cocos2d-ui/CCBReader/CCSBReader.m index b6b444c542c..5f01895ebb8 100644 --- a/cocos2d-ui/CCBReader/CCBReader.m +++ b/cocos2d-ui/CCBReader/CCSBReader.m @@ -26,7 +26,7 @@ #import #import "ccUtils.h" -#import "CCBReader_Private.h" +#import "CCSBReader_Private.h" #import "CCNode_Private.h" #import "CCDirector_Private.h" #import "CCAnimationManager_Private.h" @@ -34,16 +34,16 @@ #import "CCFileUtils.h" #import "CGPointExtension.h" -#import "CCBSequence.h" -#import "CCBKeyframe.h" -#import "CCBLocalizationManager.h" +#import "CCSequence.h" +#import "CCKeyframe.h" +#import "CCLocalizationManager.h" #import "CCSpriteFrameCache.h" #import "CCPhysics+ObjectiveChipmunk.h" #import "CCEffectStack.h" #import "CCTexture.h" #import "CCColor.h" #import "CCProtocols.h" - +#import "CCDeprecated.h" #ifdef CCB_ENABLE_UNZIP #import "SSZipArchive.h" @@ -64,7 +64,7 @@ @interface CCBFile : CCNode @end -@interface CCBReader() +@interface CCSBReader() { } @@ -75,7 +75,7 @@ @interface CCBReader() @end -@implementation CCBReader +@implementation CCSBReader @synthesize animationManager; @@ -145,19 +145,19 @@ - (void) dealloc bytes = NULL; } -static inline unsigned char readByte(CCBReader *self) +static inline unsigned char readByte(CCSBReader *self) { unsigned char byte = self->bytes[self->currentByte]; self->currentByte++; return byte; } -static inline BOOL readBool(CCBReader *self) +static inline BOOL readBool(CCSBReader *self) { return (BOOL)readByte(self); } -static inline NSString *readUTF8(CCBReader *self) +static inline NSString *readUTF8(CCSBReader *self) { int b0 = readByte(self); int b1 = readByte(self); @@ -171,7 +171,7 @@ static inline BOOL readBool(CCBReader *self) return str; } -static inline void alignBits(CCBReader *self) +static inline void alignBits(CCSBReader *self) { if (self->currentBit) { @@ -198,7 +198,7 @@ static inline ptrdiff_t readVariableLengthIntFromArray(const uint8_t* buffer, ui } -static inline int readIntWithSign(CCBReader *self, BOOL pSigned) +static inline int readIntWithSign(CCSBReader *self, BOOL pSigned) { unsigned int value = 0; self->currentByte += readVariableLengthIntFromArray(self->bytes + self->currentByte, &value); @@ -226,7 +226,7 @@ static inline int readIntWithSign(CCBReader *self, BOOL pSigned) //DEPRICATED //DEPRICATED //DEPRICATED -static inline int readIntWithSignOLD(CCBReader *self, BOOL sign) +static inline int readIntWithSignOLD(CCSBReader *self, BOOL sign) { // Good luck groking this! // The basic idea is to do as little bit reading as possible and use everything in a byte contexts and avoid loops; espc ones that iterate 8 * bytes-read @@ -332,15 +332,15 @@ static inline int readIntWithSignOLD(CCBReader *self, BOOL sign) -static inline float readFloat(CCBReader *self) +static inline float readFloat(CCSBReader *self) { unsigned char type = readByte(self); - if (type == kCCBFloat0) return 0; - else if (type == kCCBFloat1) return 1; - else if (type == kCCBFloatMinus1) return -1; - else if (type == kCCBFloat05) return 0.5f; - else if (type == kCCBFloatInteger) + if (type == kCCFloat0) return 0; + else if (type == kCCFloat1) return 1; + else if (type == kCCFloatMinus1) return -1; + else if (type == kCCFloat05) return 0.5f; + else if (type == kCCFloatInteger) { return readIntWithSign(self, YES); } @@ -409,7 +409,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( NSString* valueString = nil; #endif - if (type == kCCBPropTypePosition) + if (type == kCCPropTypePosition) { float x = readFloat(self); float y = readFloat(self); @@ -445,8 +445,8 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( } } } - else if(type == kCCBPropTypePoint - || type == kCCBPropTypePointLock) + else if(type == kCCPropTypePoint + || type == kCCPropTypePointLock) { float x = readFloat(self); float y = readFloat(self); @@ -465,7 +465,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( #endif } } - else if (type == kCCBPropTypeSize) + else if (type == kCCPropTypeSize) { float w = readFloat(self); float h = readFloat(self); @@ -489,7 +489,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( [node setValue:[NSValue valueWithBytes:&sizeType objCType:@encode(CCSizeType)] forKey:[name stringByAppendingString:@"Type"]]; } } - else if (type == kCCBPropTypeScaleLock) + else if (type == kCCPropTypeScaleLock) { float x = readFloat(self); float y = readFloat(self); @@ -516,7 +516,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( } } } - else if (type == kCCBPropTypeFloatXY) + else if (type == kCCPropTypeFloatXY) { float xFloat = readFloat(self); float yFloat = readFloat(self); @@ -533,8 +533,8 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( [node setValue:[NSNumber numberWithFloat:yFloat] forKey:nameY]; } } - else if (type == kCCBPropTypeDegrees - || type == kCCBPropTypeFloat) + else if (type == kCCPropTypeDegrees + || type == kCCPropTypeFloat) { float f = readFloat(self); @@ -553,7 +553,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( } } } - else if (type == kCCBPropTypeFloatScale) + else if (type == kCCPropTypeFloatScale) { float f = readFloat(self); int sType = readIntWithSign(self, NO); @@ -568,8 +568,8 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( [node setValue:[NSNumber numberWithFloat:f] forKey:name]; } } - else if (type == kCCBPropTypeInteger - || type == kCCBPropTypeIntegerLabeled) + else if (type == kCCPropTypeInteger + || type == kCCPropTypeIntegerLabeled) { int d = readIntWithSign(self, YES); @@ -582,7 +582,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( [node setValue:[NSNumber numberWithInt:d] forKey:name]; } } - else if (type == kCCBPropTypeFloatVar) + else if (type == kCCPropTypeFloatVar) { float f = readFloat(self); float fVar = readFloat(self); @@ -598,7 +598,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( [node setValue:[NSNumber numberWithFloat:fVar] forKey:nameVar]; } } - else if (type == kCCBPropTypeCheck) + else if (type == kCCPropTypeCheck) { BOOL b = readBool(self); @@ -617,7 +617,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( } } } - else if (type == kCCBPropTypeSpriteFrame) + else if (type == kCCPropTypeSpriteFrame) { NSString* spriteFile = [self readCachedString]; @@ -640,7 +640,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( } } } - else if (type == kCCBPropTypeTexture) + else if (type == kCCPropTypeTexture) { NSString* spriteFile = [self readCachedString]; @@ -658,7 +658,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( #endif } } - else if (type == kCCBPropTypeByte) + else if (type == kCCPropTypeByte) { int byte = readByte(self); @@ -677,8 +677,8 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( } } } - else if (type == kCCBPropTypeColor4 || - type == kCCBPropTypeColor3) + else if (type == kCCPropTypeColor4 || + type == kCCPropTypeColor3) { CGFloat r = readFloat(self); CGFloat g = readFloat(self); @@ -701,7 +701,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( } } } - else if (type == kCCBPropTypeColor4FVar) + else if (type == kCCPropTypeColor4FVar) { float r = readFloat(self); float g = readFloat(self); @@ -725,7 +725,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( [node setValue:cVarVal forKey:nameVar]; } } - else if (type == kCCBPropTypeFlip) + else if (type == kCCPropTypeFlip) { BOOL xFlip = readBool(self); BOOL yFlip = readBool(self); @@ -743,7 +743,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( [node setValue:[NSNumber numberWithBool:yFlip] forKey:nameY]; } } - else if (type == kCCBPropTypeBlendmode) + else if (type == kCCPropTypeBlendmode) { #if DEBUG_READER_PROPERTIES valueString = [NSString stringWithFormat:@"{%i, %i}", src, dst]; @@ -761,7 +761,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( }]]; } } - else if (type == kCCBPropTypeFntFile) + else if (type == kCCPropTypeFntFile) { NSString* fntFile = [self readCachedString]; [node setValue:fntFile forKey:name]; @@ -770,8 +770,8 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( valueString = [NSString stringWithFormat:@"%@", fntFile]; #endif } - else if (type == kCCBPropTypeText - || type == kCCBPropTypeString) + else if (type == kCCPropTypeText + || type == kCCPropTypeString) { NSString* txt = [self readCachedString]; BOOL localized = readBool(self); @@ -793,7 +793,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( [node setValue:txt forKey:name]; } } - else if (type == kCCBPropTypeFontTTF) + else if (type == kCCPropTypeFontTTF) { NSString* fnt = [self readCachedString]; @@ -810,7 +810,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( [node setValue:fnt forKey:name]; } } - else if (type == kCCBPropTypeBlock) + else if (type == kCCPropTypeBlock) { NSString* selectorName = [self readCachedString]; int selectorTarget = readIntWithSign(self, NO); @@ -825,8 +825,8 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( if (selectorTarget) { id target = NULL; - if (selectorTarget == kCCBTargetTypeDocumentRoot) target = animationManager.rootNode; - else if (selectorTarget == kCCBTargetTypeOwner) target = owner; + if (selectorTarget == kCCTargetTypeDocumentRoot) target = animationManager.rootNode; + else if (selectorTarget == kCCTargetTypeOwner) target = owner; if (target) { @@ -849,7 +849,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( } else { - NSLog(@"CCBReader: Failed to set selector/target block for \"%@\" for target %@",selectorName,target); + NSLog(@"CCSBReader: Failed to set selector/target block for \"%@\" for target %@",selectorName,target); } #if DEBUG_READER_PROPERTIES @@ -858,19 +858,19 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( } else { - NSLog(@"CCBReader: Failed to find target for block"); + NSLog(@"CCSBReader: Failed to find target for block"); } } } } - else if (type == kCCBPropTypeCCBFile) + else if (type == kCCPropTypeCCBFile) { NSString* ccbFileName = [self readCachedString]; - // Change path extension to .ccbi - if ([ccbFileName hasSuffix:@".ccb"]) ccbFileName = [ccbFileName stringByDeletingPathExtension]; + // Change path extension to .sbi + if ([ccbFileName hasSuffix:@".sb"]) ccbFileName = [ccbFileName stringByDeletingPathExtension]; - ccbFileName = [NSString stringWithFormat:@"%@.ccbi", ccbFileName]; + ccbFileName = [NSString stringWithFormat:@"%@.sbi", ccbFileName]; #if DEBUG_READER_PROPERTIES valueString = [NSString stringWithFormat:@"%@", ccbFileName]; @@ -882,16 +882,16 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( #if DEBUG // Special case: scroll view missing content node - if (!d && [ccbFileName isEqualToString:@".ccbi"] && [NSStringFromClass([node class]) isEqualToString:@"CCScrollView"]) + if (!d && [ccbFileName isEqualToString:@".sbi"] && [NSStringFromClass([node class]) isEqualToString:@"CCScrollView"]) { NSLog(@"*** [PROPERTY] ERROR HINT: Did you forget to set the content node for your CCScrollView?"); } #endif - NSAssert(d,@"[PROPERTY] %@ - kCCBPropTypeCCBFile - Failed to find ccb file: \"%@\", node class name: \"%@\", name: \"%@\", in ccb file: \"%@\"", + NSAssert(d,@"[PROPERTY] %@ - kCCPropTypeCCBFile - Failed to find ccb file: \"%@\", node class name: \"%@\", name: \"%@\", in ccb file: \"%@\"", name, ccbFileName, [node class], [node name], _currentCCBFile); - CCBReader* reader = [[CCBReader alloc] init]; + CCSBReader* reader = [[CCSBReader alloc] init]; reader.animationManager.rootContainerSize = parent.contentSize; // Setup byte array & owner @@ -917,7 +917,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( [node setValue:ccbFile forKey:name]; } } - else if(type == kCCBPropTypeNodeReference) + else if(type == kCCPropTypeNodeReference) { int uuid = readIntWithSign(self, NO); @@ -926,7 +926,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( [postDeserializationUUIDFixup addObject:queuedFixupTask]; } - else if(type == kCCBPropTypeFloatCheck) + else if(type == kCCPropTypeFloatCheck) { float f = readFloat(self); bool enabled = readBool(self); @@ -937,7 +937,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( [node setValue:@(f) forKey:name]; } } - else if(type == kCCBPropTypeEffects) + else if(type == kCCPropTypeEffects) { CCEffect * effect = [self readEffects]; @@ -948,7 +948,7 @@ - (void) readPropertyForNode:(CCNode*) node parent:(CCNode*)parent isExtraProp:( } } - else if(type == kCCBPropTypeTokenArray) + else if(type == kCCPropTypeTokenArray) { NSString *arrayString = [self readCachedString]; if(![arrayString isEqualToString:@""]) @@ -984,7 +984,7 @@ -(CCEffect*)readEffects Class nodeClass = NSClassFromString(className); if (nodeClass == nil) { - NSAssert(nil, @"CCBReader: Could not create class named: %@", className); + NSAssert(nil, @"CCSBReader: Could not create class named: %@", className); return nil; } @@ -1076,9 +1076,9 @@ - (NSArray *)getIvarNamesOfClass:(Class)class return result; } -- (CCBKeyframe*) readKeyframeOfType:(int)type +- (CCKeyframe*) readKeyframeOfType:(int)type { - CCBKeyframe* keyframe = [[CCBKeyframe alloc] init]; + CCKeyframe* keyframe = [[CCKeyframe alloc] init]; keyframe.time = readFloat(self); @@ -1086,27 +1086,27 @@ - (CCBKeyframe*) readKeyframeOfType:(int)type float easingOpt = 0; id value = NULL; - if (easingType == kCCBKeyframeEasingCubicIn - || easingType == kCCBKeyframeEasingCubicOut - || easingType == kCCBKeyframeEasingCubicInOut - || easingType == kCCBKeyframeEasingElasticIn - || easingType == kCCBKeyframeEasingElasticOut - || easingType == kCCBKeyframeEasingElasticInOut) + if (easingType == kCCKeyframeEasingCubicIn + || easingType == kCCKeyframeEasingCubicOut + || easingType == kCCKeyframeEasingCubicInOut + || easingType == kCCKeyframeEasingElasticIn + || easingType == kCCKeyframeEasingElasticOut + || easingType == kCCKeyframeEasingElasticInOut) { easingOpt = readFloat(self); } keyframe.easingType = easingType; keyframe.easingOpt = easingOpt; - if (type == kCCBPropTypeCheck) + if (type == kCCPropTypeCheck) { value = [NSNumber numberWithBool:readBool(self)]; } - else if (type == kCCBPropTypeByte) + else if (type == kCCPropTypeByte) { value = [NSNumber numberWithInt:readBool(self)]; } - else if (type == kCCBPropTypeColor3) + else if (type == kCCPropTypeColor3) { CGFloat r = readFloat(self); CGFloat g = readFloat(self); @@ -1115,13 +1115,13 @@ - (CCBKeyframe*) readKeyframeOfType:(int)type value = [CCColor colorWithRed:r green:g blue:b alpha:a]; } - else if (type == kCCBPropTypeDegrees || type == kCCBPropTypeFloat) + else if (type == kCCPropTypeDegrees || type == kCCPropTypeFloat) { value = [NSNumber numberWithFloat:readFloat(self)]; } - else if (type == kCCBPropTypeScaleLock - || type == kCCBPropTypePosition - || type == kCCBPropTypeFloatXY) + else if (type == kCCPropTypeScaleLock + || type == kCCPropTypePosition + || type == kCCPropTypeFloatXY) { float a = readFloat(self); float b = readFloat(self); @@ -1131,7 +1131,7 @@ - (CCBKeyframe*) readKeyframeOfType:(int)type [NSNumber numberWithFloat:b], nil]; } - else if (type == kCCBPropTypeSpriteFrame) + else if (type == kCCPropTypeSpriteFrame) { NSString* spriteFile = [self readCachedString]; @@ -1145,7 +1145,7 @@ - (CCBKeyframe*) readKeyframeOfType:(int)type return keyframe; } -- (void) didLoadFromCCB +- (void) didLoadFromSB { } @@ -1161,7 +1161,7 @@ -(void)postDeserialization return; CCNode * mappedNode = nodeMapping[@(uuid)]; - NSAssert(mappedNode != nil, @"CCBReader: Failed to find node UUID:%i", uuid); + NSAssert(mappedNode != nil, @"CCSBReader: Failed to find node UUID:%i", uuid); [node setValue:mappedNode forKey:name]; } @@ -1328,7 +1328,7 @@ -(CCNode*) nodeFromClassName:(NSString*)nodeClassName Class nodeClass = NSClassFromString(nodeClassName); if (nodeClass == nil) { - NSAssert(nil, @"CCBReader: Could not create class named: %@", nodeClassName); + NSAssert(nil, @"CCSBReader: Could not create class named: %@", nodeClassName); return nil; } @@ -1416,7 +1416,7 @@ - (CCNode*) readNodeGraphParent:(CCNode*)parent for (int j = 0; j < numProps; j++) { - CCBSequenceProperty* seqProp = [[CCBSequenceProperty alloc] init]; + CCSequenceProperty* seqProp = [[CCSequenceProperty alloc] init]; seqProp.name = [self readCachedString]; seqProp.type = readIntWithSign(self, NO); @@ -1426,11 +1426,11 @@ - (CCNode*) readNodeGraphParent:(CCNode*)parent for (int k = 0; k < numKeyframes; k++) { - CCBKeyframe* keyframe = [self readKeyframeOfType:seqProp.type]; + CCKeyframe* keyframe = [self readKeyframeOfType:seqProp.type]; if(k==0 && keyframe.time > 0.0f) { - CCBKeyframe * copyKeyframe = [keyframe copy]; + CCKeyframe * copyKeyframe = [keyframe copy]; copyKeyframe.time = 0.0f; [seqProp.keyframes addObject:copyKeyframe]; } @@ -1493,8 +1493,8 @@ - (CCNode*) readNodeGraphParent:(CCNode*)parent if (memberVarAssignmentType) { id target = NULL; - if (memberVarAssignmentType == kCCBTargetTypeDocumentRoot) target = animationManager.rootNode; - else if (memberVarAssignmentType == kCCBTargetTypeOwner) target = owner; + if (memberVarAssignmentType == kCCTargetTypeDocumentRoot) target = animationManager.rootNode; + else if (memberVarAssignmentType == kCCTargetTypeOwner) target = owner; const char *varName = [memberVarAssignmentName UTF8String]; if (target) @@ -1516,7 +1516,7 @@ - (CCNode*) readNodeGraphParent:(CCNode*)parent } else { - NSLog(@"CCBReader: Couldn't find member variable: %@", memberVarAssignmentName); + NSLog(@"CCSBReader: Couldn't find member variable: %@", memberVarAssignmentName); } } } @@ -1663,13 +1663,13 @@ - (CCNode*) readNodeGraphParent:(CCNode*)parent return node; } -- (BOOL) readCallbackKeyframesForSeq:(CCBSequence*)seq +- (BOOL) readCallbackKeyframesForSeq:(CCSequence*)seq { int numKeyframes = readIntWithSign(self, NO); if (!numKeyframes) return YES; - CCBSequenceProperty* channel = [[CCBSequenceProperty alloc] init]; + CCSequenceProperty* channel = [[CCSequenceProperty alloc] init]; for (int i = 0; i < numKeyframes; i++) { @@ -1682,7 +1682,7 @@ - (BOOL) readCallbackKeyframesForSeq:(CCBSequence*)seq [NSNumber numberWithInt:callbackType], nil]; - CCBKeyframe* keyframe = [[CCBKeyframe alloc] init]; + CCKeyframe* keyframe = [[CCKeyframe alloc] init]; keyframe.time = time; keyframe.value = value; @@ -1695,13 +1695,13 @@ - (BOOL) readCallbackKeyframesForSeq:(CCBSequence*)seq return YES; } -- (BOOL) readSoundKeyframesForSeq:(CCBSequence*)seq +- (BOOL) readSoundKeyframesForSeq:(CCSequence*)seq { int numKeyframes = readIntWithSign(self, NO); if (!numKeyframes) return YES; - CCBSequenceProperty* channel = [[CCBSequenceProperty alloc] init]; + CCSequenceProperty* channel = [[CCSequenceProperty alloc] init]; for (int i = 0; i < numKeyframes; i++) { @@ -1717,7 +1717,7 @@ - (BOOL) readSoundKeyframesForSeq:(CCBSequence*)seq [NSNumber numberWithFloat:pan], [NSNumber numberWithFloat:gain], nil]; - CCBKeyframe* keyframe = [[CCBKeyframe alloc] init]; + CCKeyframe* keyframe = [[CCKeyframe alloc] init]; keyframe.time = time; keyframe.value = value; @@ -1740,7 +1740,7 @@ - (BOOL) readSequences for (int i = 0; i < numSeqs; i++) { - CCBSequence* seq = [[CCBSequence alloc] init]; + CCSequence* seq = [[CCSequence alloc] init]; seq.duration = readFloat(self); seq.name = [self readCachedString]; seq.sequenceId = readIntWithSign(self, NO); @@ -1784,9 +1784,9 @@ - (BOOL) readHeader // Read version int version = readIntWithSignOLD(self, NO); - if (version != kCCBVersion) + if (version != kCCVersion) { - [NSException raise:NSInternalInconsistencyException format:@"CCBReader: Incompatible ccbi file version (file: %d reader: %d)",version,kCCBVersion]; + [NSException raise:NSInternalInconsistencyException format:@"CCSBReader: Incompatible sbi file version (file: %d reader: %d)",version,kCCVersion]; return NO; } @@ -1825,15 +1825,20 @@ - (CCNode*) readFileWithCleanUp:(BOOL)cleanUp actionManagers:(NSMutableDictionar return node; } -+ (void) callDidLoadFromCCBForNodeGraph:(CCNode*)nodeGraph ++ (void) calldidLoadFromSBForNodeGraph:(CCNode*)nodeGraph { for (CCNode* child in nodeGraph.children) { - [CCBReader callDidLoadFromCCBForNodeGraph:child]; + [CCSBReader calldidLoadFromSBForNodeGraph:child]; } - if ([nodeGraph respondsToSelector:@selector(didLoadFromCCB)]) + if ([nodeGraph respondsToSelector:@selector(didLoadFromSB)]) + { + [nodeGraph performSelector:@selector(didLoadFromSB)]; + } + else if([nodeGraph respondsToSelector:@selector(didLoadFromCCB)]) { + CCLOGWARN(@"Deprecation: didLoadFromCCB has been deprecated, use didLoadFromSB instead."); [nodeGraph performSelector:@selector(didLoadFromCCB)]; } } @@ -1869,16 +1874,16 @@ - (CCNode*) loadWithData:(NSData*)d owner:(id)o node.userObject = manager;//Backwards Compatible. } - // Call didLoadFromCCB - [CCBReader callDidLoadFromCCBForNodeGraph:nodeGraph]; + // Call didLoadFromSB + [CCSBReader calldidLoadFromSBForNodeGraph:nodeGraph]; return nodeGraph; } - (CCNode*) nodeGraphFromFile:(NSString*) file owner:(id)o parentSize:(CGSize)parentSize { - // Add ccbi suffix - if (![file hasSuffix:@".ccbi"]) file = [file stringByAppendingString:@".ccbi"]; + // Add sbi suffix + if (![file hasSuffix:@".sbi"]) file = [file stringByAppendingString:@".sbi"]; NSString* path = [[CCFileUtils sharedFileUtils] fullPathForFilename:file]; NSData* d = [NSData dataWithContentsOfFile:path]; @@ -1905,34 +1910,34 @@ +(void) setResourcePath:(NSString *)searchPath [[CCFileUtils sharedFileUtils] setSearchPath:array]; } -+ (CCBReader*) reader ++ (CCSBReader*) reader { - return [[CCBReader alloc] init]; + return [[CCSBReader alloc] init]; } + (CCNode*) load:(NSString*) file owner:(id)owner { - return [CCBReader load:file owner:owner parentSize:[CCDirector currentDirector].designSize]; + return [CCSBReader load:file owner:owner parentSize:[CCDirector currentDirector].designSize]; } + (CCNode*) nodeGraphFromData:(NSData*) data owner:(id)owner parentSize:(CGSize)parentSize { - return [[CCBReader reader] loadWithData:data owner:owner]; + return [[CCSBReader reader] loadWithData:data owner:owner]; } + (CCNode*) load:(NSString*) file owner:(id)owner parentSize:(CGSize)parentSize { - return [[CCBReader reader] nodeGraphFromFile:file owner:owner parentSize:parentSize]; + return [[CCSBReader reader] nodeGraphFromFile:file owner:owner parentSize:parentSize]; } + (CCNode*) load:(NSString*) file { - return [CCBReader load:file owner:NULL]; + return [CCSBReader load:file owner:NULL]; } + (CCScene*) loadAsScene:(NSString *)file owner:(id)owner { - return [CCBReader sceneWithNodeGraphFromFile:file owner:owner parentSize:[CCDirector currentDirector].designSize]; + return [CCSBReader sceneWithNodeGraphFromFile:file owner:owner parentSize:[CCDirector currentDirector].designSize]; } -(CCScene*) createScene @@ -1942,7 +1947,7 @@ -(CCScene*) createScene + (CCScene*) sceneWithNodeGraphFromFile:(NSString *)file owner:(id)owner parentSize:(CGSize)parentSize { - CCNode* node = [CCBReader load:file owner:owner parentSize:parentSize]; + CCNode* node = [CCSBReader load:file owner:owner parentSize:parentSize]; CCScene* scene = [CCScene node]; [scene addChild:node]; return scene; @@ -1950,13 +1955,13 @@ + (CCScene*) sceneWithNodeGraphFromFile:(NSString *)file owner:(id)owner parentS + (CCScene*) loadAsScene:(NSString*) file { - return [CCBReader loadAsScene:file owner:NULL]; + return [CCSBReader loadAsScene:file owner:NULL]; } + (NSString*) ccbDirectoryPath { NSArray *searchPaths = NSSearchPathForDirectoriesInDomains(NSCachesDirectory, NSUserDomainMask, YES); - return [[searchPaths objectAtIndex:0] stringByAppendingPathComponent:@"ccb"]; + return [[searchPaths objectAtIndex:0] stringByAppendingPathComponent:@"sb"]; } @end diff --git a/cocos2d-ui/CCBReader/CCSBReader_Private.h b/cocos2d-ui/CCBReader/CCSBReader_Private.h new file mode 100644 index 00000000000..b4973f37245 --- /dev/null +++ b/cocos2d-ui/CCBReader/CCSBReader_Private.h @@ -0,0 +1,91 @@ +// +// CCSBReader_Private.h +// cocos2d-ios +// +// Created by Viktor on 11/13/13. +// +// + +#import "CCSBReader.h" + +#define kCCVersion 11 + +enum { + kCCPropTypePosition = 0, + kCCPropTypeSize, + kCCPropTypePoint, + kCCPropTypePointLock, + kCCPropTypeScaleLock, + kCCPropTypeDegrees, + kCCPropTypeInteger, + kCCPropTypeFloat, + kCCPropTypeFloatVar, + kCCPropTypeCheck, + kCCPropTypeSpriteFrame, + kCCPropTypeTexture, + kCCPropTypeByte, + kCCPropTypeColor3, + kCCPropTypeColor4FVar, + kCCPropTypeFlip, + kCCPropTypeBlendmode, + kCCPropTypeFntFile, + kCCPropTypeText, + kCCPropTypeFontTTF, + kCCPropTypeIntegerLabeled, + kCCPropTypeBlock, + kCCPropTypeAnimation, + kCCPropTypeCCBFile, + kCCPropTypeString, + kCCPropTypeBlockCCControl, + kCCPropTypeFloatScale, + kCCPropTypeFloatXY, + kCCPropTypeColor4, + kCCPropTypeNodeReference, + kCCPropTypeFloatCheck, + kCCPropTypeEffects, + kCCPropTypeTokenArray +}; + +enum { + kCCFloat0 = 0, + kCCFloat1, + kCCFloatMinus1, + kCCFloat05, + kCCFloatInteger, + kCCFloatFull +}; + +enum { + kCCPlatformAll = 0, + kCCPlatformIOS, + kCCPlatformMac +}; + +enum { + kCCTargetTypeNone = 0, + kCCTargetTypeDocumentRoot = 1, + kCCTargetTypeOwner = 2, +}; + +enum +{ + kCCKeyframeEasingInstant, + + kCCKeyframeEasingLinear, + + kCCKeyframeEasingCubicIn, + kCCKeyframeEasingCubicOut, + kCCKeyframeEasingCubicInOut, + + kCCKeyframeEasingElasticIn, + kCCKeyframeEasingElasticOut, + kCCKeyframeEasingElasticInOut, + + kCCKeyframeEasingBounceIn, + kCCKeyframeEasingBounceOut, + kCCKeyframeEasingBounceInOut, + + kCCKeyframeEasingBackIn, + kCCKeyframeEasingBackOut, + kCCKeyframeEasingBackInOut, +}; diff --git a/cocos2d-ui/CCBReader/CCBSequence.h b/cocos2d-ui/CCBReader/CCSequence.h similarity index 89% rename from cocos2d-ui/CCBReader/CCBSequence.h rename to cocos2d-ui/CCBReader/CCSequence.h index 69f00163e79..51370cc3221 100644 --- a/cocos2d-ui/CCBReader/CCBSequence.h +++ b/cocos2d-ui/CCBReader/CCSequence.h @@ -25,9 +25,9 @@ #import -@class CCBSequenceProperty; +@class CCSequenceProperty; -@interface CCBSequence : NSObject +@interface CCSequence : NSObject @property (nonatomic,assign) float duration; @property (nonatomic,assign) float time; @@ -38,7 +38,7 @@ @property (nonatomic,assign) float tween; // Channels -@property (nonatomic,strong) CCBSequenceProperty* callbackChannel; -@property (nonatomic,strong) CCBSequenceProperty* soundChannel; +@property (nonatomic,strong) CCSequenceProperty* callbackChannel; +@property (nonatomic,strong) CCSequenceProperty* soundChannel; @end diff --git a/cocos2d-ui/CCBReader/CCBsequence.m b/cocos2d-ui/CCBReader/CCSequence.m similarity index 96% rename from cocos2d-ui/CCBReader/CCBsequence.m rename to cocos2d-ui/CCBReader/CCSequence.m index e762b82a005..eef78e6f85b 100644 --- a/cocos2d-ui/CCBReader/CCBsequence.m +++ b/cocos2d-ui/CCBReader/CCSequence.m @@ -23,9 +23,9 @@ * THE SOFTWARE. */ -#import "CCBSequence.h" +#import "CCSequence.h" -@implementation CCBSequence +@implementation CCSequence - (id)init { diff --git a/cocos2d-ui/CCBReader/CCBSequenceProperty.h b/cocos2d-ui/CCBReader/CCSequenceProperty.h similarity index 83% rename from cocos2d-ui/CCBReader/CCBSequenceProperty.h rename to cocos2d-ui/CCBReader/CCSequenceProperty.h index bbf06da4637..a6c1017d151 100644 --- a/cocos2d-ui/CCBReader/CCBSequenceProperty.h +++ b/cocos2d-ui/CCBReader/CCSequenceProperty.h @@ -24,17 +24,17 @@ */ #import -#import "CCBReader_Private.h" +#import "CCSBReader_Private.h" -typedef NS_ENUM(NSInteger, CCBSequencePropertyType) { - CCBSequencePropertyTypeSpriteFrame = kCCBPropTypeSpriteFrame +typedef NS_ENUM(NSInteger, CCSequencePropertyType) { + CCSequencePropertyTypeSpriteFrame = kCCPropTypeSpriteFrame }; -@interface CCBSequenceProperty : NSObject +@interface CCSequenceProperty : NSObject @property (nonatomic,strong) NSString* name; @property (nonatomic,assign) int type; @property (nonatomic,readonly) NSMutableArray* keyframes; -+ (NSString *)getPropertyNameFromTypeId:(CCBSequencePropertyType)propertyType; ++ (NSString *)getPropertyNameFromTypeId:(CCSequencePropertyType)propertyType; @end diff --git a/cocos2d-ui/CCBReader/CCBSequenceProperty.m b/cocos2d-ui/CCBReader/CCSequenceProperty.m similarity index 89% rename from cocos2d-ui/CCBReader/CCBSequenceProperty.m rename to cocos2d-ui/CCBReader/CCSequenceProperty.m index c339916cd21..967383d1697 100644 --- a/cocos2d-ui/CCBReader/CCBSequenceProperty.m +++ b/cocos2d-ui/CCBReader/CCSequenceProperty.m @@ -23,9 +23,9 @@ * THE SOFTWARE. */ -#import "CCBSequenceProperty.h" +#import "CCSequenceProperty.h" -@implementation CCBSequenceProperty +@implementation CCSequenceProperty - (id) init { @@ -45,10 +45,10 @@ - (NSString *)description { return description; } -+ (NSString *)getPropertyNameFromTypeId:(CCBSequencePropertyType)propertyType { ++ (NSString *)getPropertyNameFromTypeId:(CCSequencePropertyType)propertyType { switch(propertyType) { - case CCBSequencePropertyTypeSpriteFrame: + case CCSequencePropertyTypeSpriteFrame: return @"spriteFrame"; break; } diff --git a/cocos2d-ui/cocos2d-ui.h b/cocos2d-ui/cocos2d-ui.h index 03f3ba7d2c0..04c010c17b5 100644 --- a/cocos2d-ui/cocos2d-ui.h +++ b/cocos2d-ui/cocos2d-ui.h @@ -30,5 +30,5 @@ #import "CCTextField.h" #import "CCSlider.h" -// CCBReader +// CCSBReader #import "CCBuilderReader.h" diff --git a/cocos2d.xcodeproj/project.pbxproj b/cocos2d.xcodeproj/project.pbxproj index 133fd7fd8c6..350428b0540 100644 --- a/cocos2d.xcodeproj/project.pbxproj +++ b/cocos2d.xcodeproj/project.pbxproj @@ -263,14 +263,13 @@ 7A59476619E3731600F65F90 /* CCAnimationManager_Private.h in Headers */ = {isa = PBXBuildFile; fileRef = D24160F61958F6EE003673BD /* CCAnimationManager_Private.h */; }; 7A59476719E3731600F65F90 /* CCAnimationManager.h in Headers */ = {isa = PBXBuildFile; fileRef = D24160F71958F6EE003673BD /* CCAnimationManager.h */; }; 7A59476919E3731700F65F90 /* CCAnimationManager+FrameAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = D24160F91958F6EE003673BD /* CCAnimationManager+FrameAnimation.h */; }; - 7A59476B19E3731800F65F90 /* CCBAnimationManager.h in Headers */ = {isa = PBXBuildFile; fileRef = D24160FB1958F6EE003673BD /* CCBAnimationManager.h */; }; - 7A59476D19E3731800F65F90 /* CCBKeyframe.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273021822F4AA0054849B /* CCBKeyframe.h */; }; - 7A59476F19E3731900F65F90 /* CCBLocalizationManager.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273041822F4AA0054849B /* CCBLocalizationManager.h */; }; - 7A59477119E3731A00F65F90 /* CCBReader.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273061822F4AA0054849B /* CCBReader.h */; }; - 7A59477319E3731B00F65F90 /* CCBSequence.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273081822F4AA0054849B /* CCBSequence.h */; }; - 7A59477519E3731C00F65F90 /* CCBSequenceProperty.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D2730A1822F4AA0054849B /* CCBSequenceProperty.h */; }; + 7A59476D19E3731800F65F90 /* CCKeyframe.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273021822F4AA0054849B /* CCKeyframe.h */; }; + 7A59476F19E3731900F65F90 /* CCLocalizationManager.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273041822F4AA0054849B /* CCLocalizationManager.h */; }; + 7A59477119E3731A00F65F90 /* CCSBReader.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273061822F4AA0054849B /* CCSBReader.h */; }; + 7A59477319E3731B00F65F90 /* CCSequence.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273081822F4AA0054849B /* CCSequence.h */; }; + 7A59477519E3731C00F65F90 /* CCSequenceProperty.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D2730A1822F4AA0054849B /* CCSequenceProperty.h */; }; 7A59477719E3731C00F65F90 /* CCBuilderReader.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D2730C1822F4AA0054849B /* CCBuilderReader.h */; }; - 7A59477819E3731D00F65F90 /* CCBReader_Private.h in Headers */ = {isa = PBXBuildFile; fileRef = B77060CE18341AD50043CC67 /* CCBReader_Private.h */; }; + 7A59477819E3731D00F65F90 /* CCSBReader_Private.h in Headers */ = {isa = PBXBuildFile; fileRef = B77060CE18341AD50043CC67 /* CCSBReader_Private.h */; }; 7A59477919E3731D00F65F90 /* cocos2d-ui.h in Headers */ = {isa = PBXBuildFile; fileRef = B7C6237917EA7D8600928F91 /* cocos2d-ui.h */; }; 7A59477A19E3731E00F65F90 /* CCControl.h in Headers */ = {isa = PBXBuildFile; fileRef = B78AE45C17E7AF1C0028BE0B /* CCControl.h */; }; 7A59477B19E3731E00F65F90 /* CCControlSubclass.h in Headers */ = {isa = PBXBuildFile; fileRef = B750162218124B6000708A2F /* CCControlSubclass.h */; }; @@ -379,12 +378,11 @@ 7A5948B019E375B900F65F90 /* CCPlatformTextFieldMac.m in Sources */ = {isa = PBXBuildFile; fileRef = 571CD02519649E03003D460C /* CCPlatformTextFieldMac.m */; }; 7A5948B319E375B900F65F90 /* CCAnimationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = D24160F81958F6EE003673BD /* CCAnimationManager.m */; }; 7A5948B519E375B900F65F90 /* CCAnimationManager+FrameAnimation.m in Sources */ = {isa = PBXBuildFile; fileRef = D24160FA1958F6EE003673BD /* CCAnimationManager+FrameAnimation.m */; }; - 7A5948B719E375BA00F65F90 /* CCBAnimationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = D24160FC1958F6EE003673BD /* CCBAnimationManager.m */; }; - 7A5948B919E375BA00F65F90 /* CCBKeyframe.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273031822F4AA0054849B /* CCBKeyframe.m */; }; - 7A5948BB19E375BA00F65F90 /* CCBLocalizationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273051822F4AA0054849B /* CCBLocalizationManager.m */; }; - 7A5948BD19E375BB00F65F90 /* CCBReader.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273071822F4AA0054849B /* CCBReader.m */; }; - 7A5948BF19E375BB00F65F90 /* CCBsequence.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273091822F4AA0054849B /* CCBsequence.m */; }; - 7A5948C119E375BB00F65F90 /* CCBSequenceProperty.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D2730B1822F4AA0054849B /* CCBSequenceProperty.m */; }; + 7A5948B919E375BA00F65F90 /* CCKeyframe.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273031822F4AA0054849B /* CCKeyframe.m */; }; + 7A5948BB19E375BA00F65F90 /* CCLocalizationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273051822F4AA0054849B /* CCLocalizationManager.m */; }; + 7A5948BD19E375BB00F65F90 /* CCSBReader.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273071822F4AA0054849B /* CCSBReader.m */; }; + 7A5948BF19E375BB00F65F90 /* CCSequence.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273091822F4AA0054849B /* CCSequence.m */; }; + 7A5948C119E375BB00F65F90 /* CCSequenceProperty.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D2730B1822F4AA0054849B /* CCSequenceProperty.m */; }; 7A5948C719E375BC00F65F90 /* CCControl.m in Sources */ = {isa = PBXBuildFile; fileRef = B78AE45D17E7AF1C0028BE0B /* CCControl.m */; }; 7A5948C919E375BD00F65F90 /* CCButton.m in Sources */ = {isa = PBXBuildFile; fileRef = B78AE45B17E7AF1C0028BE0B /* CCButton.m */; }; 7A5948CB19E375BD00F65F90 /* CCTableView.m in Sources */ = {isa = PBXBuildFile; fileRef = B79F905917FE2A2E00908504 /* CCTableView.m */; }; @@ -478,7 +476,7 @@ B759E5381880C91200E8166C /* libObjectiveChipmunk-iPhone.a in Frameworks */ = {isa = PBXBuildFile; fileRef = B759E52D1880C66900E8166C /* libObjectiveChipmunk-iPhone.a */; }; B75C2E7C17C5908B002B0E0D /* NSAttributedString+CCAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = B75C2E7A17C5908B002B0E0D /* NSAttributedString+CCAdditions.h */; }; B75C2E7D17C5908B002B0E0D /* NSAttributedString+CCAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = B75C2E7B17C5908B002B0E0D /* NSAttributedString+CCAdditions.m */; }; - B77060CF18341AD50043CC67 /* CCBReader_Private.h in Headers */ = {isa = PBXBuildFile; fileRef = B77060CE18341AD50043CC67 /* CCBReader_Private.h */; }; + B77060CF18341AD50043CC67 /* CCSBReader_Private.h in Headers */ = {isa = PBXBuildFile; fileRef = B77060CE18341AD50043CC67 /* CCSBReader_Private.h */; }; B78AE46217E7AF1C0028BE0B /* CCButton.h in Headers */ = {isa = PBXBuildFile; fileRef = B78AE45A17E7AF1C0028BE0B /* CCButton.h */; }; B78AE46317E7AF1C0028BE0B /* CCButton.m in Sources */ = {isa = PBXBuildFile; fileRef = B78AE45B17E7AF1C0028BE0B /* CCButton.m */; }; B78AE46417E7AF1C0028BE0B /* CCControl.h in Headers */ = {isa = PBXBuildFile; fileRef = B78AE45C17E7AF1C0028BE0B /* CCControl.h */; }; @@ -496,16 +494,16 @@ B798D15318205EFB00E7BFCD /* CCParticleSystem_Private.h in Headers */ = {isa = PBXBuildFile; fileRef = B798D15218205EFB00E7BFCD /* CCParticleSystem_Private.h */; }; B79F905A17FE2A2E00908504 /* CCTableView.h in Headers */ = {isa = PBXBuildFile; fileRef = B79F905817FE2A2E00908504 /* CCTableView.h */; }; B79F905B17FE2A2E00908504 /* CCTableView.m in Sources */ = {isa = PBXBuildFile; fileRef = B79F905917FE2A2E00908504 /* CCTableView.m */; }; - B7D2730F1822F4AA0054849B /* CCBKeyframe.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273021822F4AA0054849B /* CCBKeyframe.h */; }; - B7D273101822F4AA0054849B /* CCBKeyframe.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273031822F4AA0054849B /* CCBKeyframe.m */; }; - B7D273111822F4AA0054849B /* CCBLocalizationManager.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273041822F4AA0054849B /* CCBLocalizationManager.h */; }; - B7D273121822F4AA0054849B /* CCBLocalizationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273051822F4AA0054849B /* CCBLocalizationManager.m */; }; - B7D273131822F4AA0054849B /* CCBReader.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273061822F4AA0054849B /* CCBReader.h */; }; - B7D273141822F4AA0054849B /* CCBReader.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273071822F4AA0054849B /* CCBReader.m */; }; - B7D273151822F4AA0054849B /* CCBSequence.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273081822F4AA0054849B /* CCBSequence.h */; }; - B7D273161822F4AA0054849B /* CCBsequence.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273091822F4AA0054849B /* CCBsequence.m */; }; - B7D273171822F4AA0054849B /* CCBSequenceProperty.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D2730A1822F4AA0054849B /* CCBSequenceProperty.h */; }; - B7D273181822F4AA0054849B /* CCBSequenceProperty.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D2730B1822F4AA0054849B /* CCBSequenceProperty.m */; }; + B7D2730F1822F4AA0054849B /* CCKeyframe.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273021822F4AA0054849B /* CCKeyframe.h */; }; + B7D273101822F4AA0054849B /* CCKeyframe.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273031822F4AA0054849B /* CCKeyframe.m */; }; + B7D273111822F4AA0054849B /* CCLocalizationManager.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273041822F4AA0054849B /* CCLocalizationManager.h */; }; + B7D273121822F4AA0054849B /* CCLocalizationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273051822F4AA0054849B /* CCLocalizationManager.m */; }; + B7D273131822F4AA0054849B /* CCSBReader.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273061822F4AA0054849B /* CCSBReader.h */; }; + B7D273141822F4AA0054849B /* CCSBReader.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273071822F4AA0054849B /* CCSBReader.m */; }; + B7D273151822F4AA0054849B /* CCSequence.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273081822F4AA0054849B /* CCSequence.h */; }; + B7D273161822F4AA0054849B /* CCSequence.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273091822F4AA0054849B /* CCSequence.m */; }; + B7D273171822F4AA0054849B /* CCSequenceProperty.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D2730A1822F4AA0054849B /* CCSequenceProperty.h */; }; + B7D273181822F4AA0054849B /* CCSequenceProperty.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D2730B1822F4AA0054849B /* CCSequenceProperty.m */; }; B7D273191822F4AA0054849B /* CCBuilderReader.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D2730C1822F4AA0054849B /* CCBuilderReader.h */; }; B7E260D818171D2000A0E872 /* CCTextField.h in Headers */ = {isa = PBXBuildFile; fileRef = B7E260D618171D2000A0E872 /* CCTextField.h */; }; B7E260D918171D2000A0E872 /* CCTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = B7E260D718171D2000A0E872 /* CCTextField.m */; }; @@ -554,8 +552,6 @@ D24160FF1958F6EE003673BD /* CCAnimationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = D24160F81958F6EE003673BD /* CCAnimationManager.m */; }; D24161001958F6EE003673BD /* CCAnimationManager+FrameAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = D24160F91958F6EE003673BD /* CCAnimationManager+FrameAnimation.h */; }; D24161011958F6EE003673BD /* CCAnimationManager+FrameAnimation.m in Sources */ = {isa = PBXBuildFile; fileRef = D24160FA1958F6EE003673BD /* CCAnimationManager+FrameAnimation.m */; }; - D24161021958F6EE003673BD /* CCBAnimationManager.h in Headers */ = {isa = PBXBuildFile; fileRef = D24160FB1958F6EE003673BD /* CCBAnimationManager.h */; }; - D24161031958F6EE003673BD /* CCBAnimationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = D24160FC1958F6EE003673BD /* CCBAnimationManager.m */; }; D24161091958F72B003673BD /* CCEffectRenderer.h in Headers */ = {isa = PBXBuildFile; fileRef = D24161041958F72B003673BD /* CCEffectRenderer.h */; }; D241610A1958F72B003673BD /* CCEffectRenderer.h in Headers */ = {isa = PBXBuildFile; fileRef = D24161041958F72B003673BD /* CCEffectRenderer.h */; }; D241610B1958F72B003673BD /* CCEffectRenderer.m in Sources */ = {isa = PBXBuildFile; fileRef = D24161051958F72B003673BD /* CCEffectRenderer.m */; }; @@ -670,7 +666,7 @@ D2DDB0A719805E8400233D80 /* CCMatrix3.m in Sources */ = {isa = PBXBuildFile; fileRef = D2DDB09219805E8400233D80 /* CCMatrix3.m */; }; D2DDB0A819805E8400233D80 /* CCMatrix3.m in Sources */ = {isa = PBXBuildFile; fileRef = D2DDB09219805E8400233D80 /* CCMatrix3.m */; }; D2EC6039199D9F82001A15E9 /* CCRendererGLSupport.m in Sources */ = {isa = PBXBuildFile; fileRef = D36DFA2719996EC500DEC135 /* CCRendererGLSupport.m */; }; - D2FEB611194F6C9E00FC0574 /* CCBLocalizationManager.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273041822F4AA0054849B /* CCBLocalizationManager.h */; }; + D2FEB611194F6C9E00FC0574 /* CCLocalizationManager.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273041822F4AA0054849B /* CCLocalizationManager.h */; }; D2FEB612194F6C9E00FC0574 /* CCAction.h in Headers */ = {isa = PBXBuildFile; fileRef = 5018F2520DFDEAFF00C013A5 /* CCAction.h */; }; D2FEB613194F6C9E00FC0574 /* CCNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 5018F2540DFDEAFF00C013A5 /* CCNode.h */; }; D2FEB614194F6C9E00FC0574 /* CCDirector.h in Headers */ = {isa = PBXBuildFile; fileRef = 5018F2560DFDEAFF00C013A5 /* CCDirector.h */; }; @@ -702,12 +698,12 @@ D2FEB647194F6C9E00FC0574 /* CCEffect_Private.h in Headers */ = {isa = PBXBuildFile; fileRef = D272031718FC89A000B100FF /* CCEffect_Private.h */; }; D2FEB648194F6C9E00FC0574 /* CCEffectStack.h in Headers */ = {isa = PBXBuildFile; fileRef = D272032018FC89A000B100FF /* CCEffectStack.h */; }; D2FEB64A194F6C9E00FC0574 /* CCTextField.h in Headers */ = {isa = PBXBuildFile; fileRef = B7E260D618171D2000A0E872 /* CCTextField.h */; }; - D2FEB64B194F6C9E00FC0574 /* CCBReader.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273061822F4AA0054849B /* CCBReader.h */; }; + D2FEB64B194F6C9E00FC0574 /* CCSBReader.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273061822F4AA0054849B /* CCSBReader.h */; }; D2FEB64C194F6C9E00FC0574 /* CCEffectPixellate.h in Headers */ = {isa = PBXBuildFile; fileRef = 9DF3761F191C594A00C6D27A /* CCEffectPixellate.h */; }; D2FEB64E194F6C9E00FC0574 /* CCTiledMap.h in Headers */ = {isa = PBXBuildFile; fileRef = 509D0816101E4FCE007E1749 /* CCTiledMap.h */; }; D2FEB652194F6C9E00FC0574 /* CCTMXXMLParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 50CFAC371023660000175934 /* CCTMXXMLParser.h */; }; D2FEB653194F6C9E00FC0574 /* CCRenderTexture.h in Headers */ = {isa = PBXBuildFile; fileRef = 50316AA410291280003ACFE7 /* CCRenderTexture.h */; }; - D2FEB654194F6C9E00FC0574 /* CCBSequenceProperty.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D2730A1822F4AA0054849B /* CCBSequenceProperty.h */; }; + D2FEB654194F6C9E00FC0574 /* CCSequenceProperty.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D2730A1822F4AA0054849B /* CCSequenceProperty.h */; }; D2FEB655194F6C9E00FC0574 /* CCMotionStreak.h in Headers */ = {isa = PBXBuildFile; fileRef = 50316AD21029A126003ACFE7 /* CCMotionStreak.h */; }; D2FEB656194F6C9E00FC0574 /* CCCache.h in Headers */ = {isa = PBXBuildFile; fileRef = D380581E1889CE7700822437 /* CCCache.h */; }; D2FEB657194F6C9E00FC0574 /* CCRenderer_Private.h in Headers */ = {isa = PBXBuildFile; fileRef = D309054F18AC23110081BF11 /* CCRenderer_Private.h */; }; @@ -720,7 +716,7 @@ D2FEB65F194F6C9E00FC0574 /* CCTexture.h in Headers */ = {isa = PBXBuildFile; fileRef = 50E1357110ADEB1B00C9E7FA /* CCTexture.h */; }; D2FEB660194F6C9E00FC0574 /* CCTiledMapLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = 50D2AC9110E90DFA0068ECEB /* CCTiledMapLayer.h */; }; D2FEB664194F6C9E00FC0574 /* CCTiledMapObjectGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = 50D2AC9310E90DFA0068ECEB /* CCTiledMapObjectGroup.h */; }; - D2FEB665194F6C9E00FC0574 /* CCBSequence.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273081822F4AA0054849B /* CCBSequence.h */; }; + D2FEB665194F6C9E00FC0574 /* CCSequence.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273081822F4AA0054849B /* CCSequence.h */; }; D2FEB667194F6C9E00FC0574 /* CCGLView.h in Headers */ = {isa = PBXBuildFile; fileRef = D285ECEE192EA92A009F4E88 /* CCGLView.h */; }; D2FEB668194F6C9E00FC0574 /* CCActionProgressTimer.h in Headers */ = {isa = PBXBuildFile; fileRef = 50150435113300F900A9CA65 /* CCActionProgressTimer.h */; }; D2FEB66B194F6C9E00FC0574 /* CCActionTween.h in Headers */ = {isa = PBXBuildFile; fileRef = 50FBB2D8117613F500150761 /* CCActionTween.h */; }; @@ -755,7 +751,7 @@ D2FEB6A6194F6C9E00FC0574 /* CCSlider.h in Headers */ = {isa = PBXBuildFile; fileRef = B7EE6A1C181AE34600B983FE /* CCSlider.h */; }; D2FEB6A7194F6C9E00FC0574 /* ccFPSImages.h in Headers */ = {isa = PBXBuildFile; fileRef = A003AC8B1657071100C7B792 /* ccFPSImages.h */; }; D2FEB6A8194F6C9E00FC0574 /* CCSprite9Slice.h in Headers */ = {isa = PBXBuildFile; fileRef = B74C2B9917BDA63A00A829C0 /* CCSprite9Slice.h */; }; - D2FEB6A9194F6C9E00FC0574 /* CCBReader_Private.h in Headers */ = {isa = PBXBuildFile; fileRef = B77060CE18341AD50043CC67 /* CCBReader_Private.h */; }; + D2FEB6A9194F6C9E00FC0574 /* CCSBReader_Private.h in Headers */ = {isa = PBXBuildFile; fileRef = B77060CE18341AD50043CC67 /* CCSBReader_Private.h */; }; D2FEB6AA194F6C9E00FC0574 /* NSAttributedString+CCAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = B75C2E7A17C5908B002B0E0D /* NSAttributedString+CCAdditions.h */; }; D2FEB6AB194F6C9E00FC0574 /* CCResponderManager.h in Headers */ = {isa = PBXBuildFile; fileRef = A6A0734317C788EB004343C8 /* CCResponderManager.h */; }; D2FEB6AC194F6C9E00FC0574 /* CCResponder.h in Headers */ = {isa = PBXBuildFile; fileRef = A6A0734817C78EF3004343C8 /* CCResponder.h */; }; @@ -765,7 +761,7 @@ D2FEB6B1194F6C9E00FC0574 /* CCControl.h in Headers */ = {isa = PBXBuildFile; fileRef = B78AE45C17E7AF1C0028BE0B /* CCControl.h */; }; D2FEB6B4194F6C9E00FC0574 /* CCScrollView.h in Headers */ = {isa = PBXBuildFile; fileRef = B78AE46017E7AF1C0028BE0B /* CCScrollView.h */; }; D2FEB6B6194F6C9E00FC0574 /* UITouch+CC.h in Headers */ = {isa = PBXBuildFile; fileRef = B78AE46A17E7AF6C0028BE0B /* UITouch+CC.h */; }; - D2FEB6B7194F6C9E00FC0574 /* CCBKeyframe.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273021822F4AA0054849B /* CCBKeyframe.h */; }; + D2FEB6B7194F6C9E00FC0574 /* CCKeyframe.h in Headers */ = {isa = PBXBuildFile; fileRef = B7D273021822F4AA0054849B /* CCKeyframe.h */; }; D2FEB6B9194F6C9E00FC0574 /* CCAction.m in Sources */ = {isa = PBXBuildFile; fileRef = 5018F2530DFDEAFF00C013A5 /* CCAction.m */; }; D2FEB6BA194F6C9E00FC0574 /* CCNode.m in Sources */ = {isa = PBXBuildFile; fileRef = 5018F2550DFDEAFF00C013A5 /* CCNode.m */; settings = {COMPILER_FLAGS = "-fno-objc-arc"; }; }; D2FEB6BB194F6C9E00FC0574 /* CCDirector.m in Sources */ = {isa = PBXBuildFile; fileRef = 5018F2570DFDEAFF00C013A5 /* CCDirector.m */; }; @@ -781,7 +777,7 @@ D2FEB6CA194F6C9E00FC0574 /* CCParticleSystemBase.m in Sources */ = {isa = PBXBuildFile; fileRef = 5038B6B10E196CD8009A621E /* CCParticleSystemBase.m */; }; D2FEB6CC194F6C9E00FC0574 /* CCScheduler.m in Sources */ = {isa = PBXBuildFile; fileRef = 506602100E38A70D000B500E /* CCScheduler.m */; settings = {COMPILER_FLAGS = "-fno-objc-arc"; }; }; D2FEB6CD194F6C9E00FC0574 /* cocos2d.m in Sources */ = {isa = PBXBuildFile; fileRef = 50A07B7A0E4CBCD300AAF0BB /* cocos2d.m */; }; - D2FEB6CF194F6C9E00FC0574 /* CCBSequenceProperty.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D2730B1822F4AA0054849B /* CCBSequenceProperty.m */; }; + D2FEB6CF194F6C9E00FC0574 /* CCSequenceProperty.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D2730B1822F4AA0054849B /* CCSequenceProperty.m */; }; D2FEB6D1194F6C9E00FC0574 /* CCTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = B7E260D718171D2000A0E872 /* CCTextField.m */; }; D2FEB6D2194F6C9E00FC0574 /* CCActionEase.m in Sources */ = {isa = PBXBuildFile; fileRef = 50F7B2770F28DE7C00057537 /* CCActionEase.m */; }; D2FEB6D3194F6C9E00FC0574 /* CCPhysicsShape.m in Sources */ = {isa = PBXBuildFile; fileRef = D3A2E7D1181E12750033614C /* CCPhysicsShape.m */; }; @@ -795,7 +791,7 @@ D2FEB6DE194F6C9E00FC0574 /* CGPointExtension.m in Sources */ = {isa = PBXBuildFile; fileRef = 503798C50F912C2000986724 /* CGPointExtension.m */; }; D2FEB6DF194F6C9E00FC0574 /* CCParticleSystem.m in Sources */ = {isa = PBXBuildFile; fileRef = 50D413250F9A3FE00040C3C8 /* CCParticleSystem.m */; }; D2FEB6E2194F6C9E00FC0574 /* CCAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = B7E775CF18527EF0004221AA /* CCAppDelegate.m */; }; - D2FEB6E3194F6C9E00FC0574 /* CCBReader.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273071822F4AA0054849B /* CCBReader.m */; }; + D2FEB6E3194F6C9E00FC0574 /* CCSBReader.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273071822F4AA0054849B /* CCSBReader.m */; }; D2FEB6EA194F6C9E00FC0574 /* CCEffectStack.m in Sources */ = {isa = PBXBuildFile; fileRef = D272032118FC89A000B100FF /* CCEffectStack.m */; }; D2FEB6EC194F6C9E00FC0574 /* CCRenderTexture.m in Sources */ = {isa = PBXBuildFile; fileRef = 50316AA510291280003ACFE7 /* CCRenderTexture.m */; }; D2FEB6ED194F6C9E00FC0574 /* CCMotionStreak.m in Sources */ = {isa = PBXBuildFile; fileRef = 50316AD31029A126003ACFE7 /* CCMotionStreak.m */; }; @@ -813,15 +809,15 @@ D2FEB6FE194F6C9E00FC0574 /* CCLabelBMFont.m in Sources */ = {isa = PBXBuildFile; fileRef = E01E6D8B121F130E001A484F /* CCLabelBMFont.m */; }; D2FEB701194F6C9E00FC0574 /* CCDirectorAndroid.m in Sources */ = {isa = PBXBuildFile; fileRef = D285ECF7192EF5B2009F4E88 /* CCDirectorAndroid.m */; }; D2FEB703194F6C9E00FC0574 /* CCEffectBrightness.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D85671C191B018200573093 /* CCEffectBrightness.m */; }; - D2FEB705194F6C9E00FC0574 /* CCBKeyframe.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273031822F4AA0054849B /* CCBKeyframe.m */; }; + D2FEB705194F6C9E00FC0574 /* CCKeyframe.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273031822F4AA0054849B /* CCKeyframe.m */; }; D2FEB706194F6C9E00FC0574 /* CCTexture+PVR.m in Sources */ = {isa = PBXBuildFile; fileRef = E0F924701224140400EF2362 /* CCTexture+PVR.m */; }; D2FEB708194F6C9E00FC0574 /* CCAnimationCache.m in Sources */ = {isa = PBXBuildFile; fileRef = E02BB6D5126CA93A006E46A2 /* CCAnimationCache.m */; }; D2FEB709194F6C9E00FC0574 /* CCAnimation.m in Sources */ = {isa = PBXBuildFile; fileRef = E02BB703126CADEA006E46A2 /* CCAnimation.m */; }; D2FEB70A194F6C9E00FC0574 /* CCShader.m in Sources */ = {isa = PBXBuildFile; fileRef = E0BC7D9C1342CE7B001B4DCC /* CCShader.m */; }; D2FEB710194F6C9E00FC0574 /* CCDirectorMac.m in Sources */ = {isa = PBXBuildFile; fileRef = A046E28C14C1DB7D0005BBF2 /* CCDirectorMac.m */; }; D2FEB712194F6C9E00FC0574 /* CCWindow.m in Sources */ = {isa = PBXBuildFile; fileRef = A046E29214C1DB7D0005BBF2 /* CCWindow.m */; }; - D2FEB714194F6C9E00FC0574 /* CCBLocalizationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273051822F4AA0054849B /* CCBLocalizationManager.m */; }; - D2FEB719194F6C9E00FC0574 /* CCBsequence.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273091822F4AA0054849B /* CCBsequence.m */; }; + D2FEB714194F6C9E00FC0574 /* CCLocalizationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273051822F4AA0054849B /* CCLocalizationManager.m */; }; + D2FEB719194F6C9E00FC0574 /* CCSequence.m in Sources */ = {isa = PBXBuildFile; fileRef = B7D273091822F4AA0054849B /* CCSequence.m */; }; D2FEB71A194F6C9E00FC0574 /* CCEffectPixellate.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DF37620191C594A00C6D27A /* CCEffectPixellate.m */; }; D2FEB71B194F6C9E00FC0574 /* CCActionCatmullRom.m in Sources */ = {isa = PBXBuildFile; fileRef = A0A7A53B1514F27D00C8BD16 /* CCActionCatmullRom.m */; }; D2FEB71D194F6C9E00FC0574 /* CCRenderer.m in Sources */ = {isa = PBXBuildFile; fileRef = D38058191889AD6000822437 /* CCRenderer.m */; }; @@ -1171,7 +1167,7 @@ 509D0817101E4FCE007E1749 /* CCTiledMap.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CCTiledMap.m; sourceTree = ""; }; 50A07B7A0E4CBCD300AAF0BB /* cocos2d.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = cocos2d.m; sourceTree = ""; }; 50AC0A500EC34DD400EB5EDC /* DONORS */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = DONORS; sourceTree = ""; }; - 50B2C9BF0E109A5900AE9530 /* CHANGELOG */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = CHANGELOG; sourceTree = ""; }; + 50B2C9BF0E109A5900AE9530 /* CHANGELOG */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; lineEnding = 0; path = CHANGELOG; sourceTree = ""; xcLanguageSpecificationIdentifier = ""; }; 50BAF3970F33CCD8003F654C /* ccMacros.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ccMacros.h; sourceTree = ""; }; 50C508C40F7C194400799124 /* CCFileUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCFileUtils.h; sourceTree = ""; }; 50C508C50F7C194400799124 /* CCFileUtils.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CCFileUtils.m; sourceTree = ""; }; @@ -1289,7 +1285,7 @@ B759E5281880C66900E8166C /* Chipmunk7-ios.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; path = "Chipmunk7-ios.xcodeproj"; sourceTree = ""; }; B75C2E7A17C5908B002B0E0D /* NSAttributedString+CCAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSAttributedString+CCAdditions.h"; sourceTree = ""; }; B75C2E7B17C5908B002B0E0D /* NSAttributedString+CCAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSAttributedString+CCAdditions.m"; sourceTree = ""; }; - B77060CE18341AD50043CC67 /* CCBReader_Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCBReader_Private.h; path = "cocos2d-ui/CCBReader/CCBReader_Private.h"; sourceTree = ""; }; + B77060CE18341AD50043CC67 /* CCSBReader_Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; name = CCSBReader_Private.h; path = "cocos2d-ui/CCBReader/CCSBReader_Private.h"; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; }; B78AE45A17E7AF1C0028BE0B /* CCButton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCButton.h; path = "cocos2d-ui/CCButton.h"; sourceTree = ""; }; B78AE45B17E7AF1C0028BE0B /* CCButton.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCButton.m; path = "cocos2d-ui/CCButton.m"; sourceTree = ""; }; B78AE45C17E7AF1C0028BE0B /* CCControl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCControl.h; path = "cocos2d-ui/CCControl.h"; sourceTree = ""; }; @@ -1308,17 +1304,17 @@ B798D15218205EFB00E7BFCD /* CCParticleSystem_Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCParticleSystem_Private.h; sourceTree = ""; }; B79F905817FE2A2E00908504 /* CCTableView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCTableView.h; path = "cocos2d-ui/CCTableView.h"; sourceTree = ""; }; B79F905917FE2A2E00908504 /* CCTableView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCTableView.m; path = "cocos2d-ui/CCTableView.m"; sourceTree = ""; }; - B7C6237917EA7D8600928F91 /* cocos2d-ui.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = "cocos2d-ui.h"; path = "cocos2d-ui/cocos2d-ui.h"; sourceTree = ""; }; - B7D273021822F4AA0054849B /* CCBKeyframe.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCBKeyframe.h; path = "cocos2d-ui/CCBReader/CCBKeyframe.h"; sourceTree = ""; }; - B7D273031822F4AA0054849B /* CCBKeyframe.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCBKeyframe.m; path = "cocos2d-ui/CCBReader/CCBKeyframe.m"; sourceTree = ""; }; - B7D273041822F4AA0054849B /* CCBLocalizationManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCBLocalizationManager.h; path = "cocos2d-ui/CCBReader/CCBLocalizationManager.h"; sourceTree = ""; }; - B7D273051822F4AA0054849B /* CCBLocalizationManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCBLocalizationManager.m; path = "cocos2d-ui/CCBReader/CCBLocalizationManager.m"; sourceTree = ""; }; - B7D273061822F4AA0054849B /* CCBReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCBReader.h; path = "cocos2d-ui/CCBReader/CCBReader.h"; sourceTree = ""; }; - B7D273071822F4AA0054849B /* CCBReader.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCBReader.m; path = "cocos2d-ui/CCBReader/CCBReader.m"; sourceTree = ""; }; - B7D273081822F4AA0054849B /* CCBSequence.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCBSequence.h; path = "cocos2d-ui/CCBReader/CCBSequence.h"; sourceTree = ""; }; - B7D273091822F4AA0054849B /* CCBsequence.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCBsequence.m; path = "cocos2d-ui/CCBReader/CCBsequence.m"; sourceTree = ""; }; - B7D2730A1822F4AA0054849B /* CCBSequenceProperty.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCBSequenceProperty.h; path = "cocos2d-ui/CCBReader/CCBSequenceProperty.h"; sourceTree = ""; }; - B7D2730B1822F4AA0054849B /* CCBSequenceProperty.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCBSequenceProperty.m; path = "cocos2d-ui/CCBReader/CCBSequenceProperty.m"; sourceTree = ""; }; + B7C6237917EA7D8600928F91 /* cocos2d-ui.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; lineEnding = 0; name = "cocos2d-ui.h"; path = "cocos2d-ui/cocos2d-ui.h"; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; }; + B7D273021822F4AA0054849B /* CCKeyframe.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCKeyframe.h; path = "cocos2d-ui/CCBReader/CCKeyframe.h"; sourceTree = ""; }; + B7D273031822F4AA0054849B /* CCKeyframe.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCKeyframe.m; path = "cocos2d-ui/CCBReader/CCKeyframe.m"; sourceTree = ""; }; + B7D273041822F4AA0054849B /* CCLocalizationManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCLocalizationManager.h; path = "cocos2d-ui/CCBReader/CCLocalizationManager.h"; sourceTree = ""; }; + B7D273051822F4AA0054849B /* CCLocalizationManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCLocalizationManager.m; path = "cocos2d-ui/CCBReader/CCLocalizationManager.m"; sourceTree = ""; }; + B7D273061822F4AA0054849B /* CCSBReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; name = CCSBReader.h; path = "cocos2d-ui/CCBReader/CCSBReader.h"; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; }; + B7D273071822F4AA0054849B /* CCSBReader.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; lineEnding = 0; name = CCSBReader.m; path = "cocos2d-ui/CCBReader/CCSBReader.m"; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.objc; }; + B7D273081822F4AA0054849B /* CCSequence.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCSequence.h; path = "cocos2d-ui/CCBReader/CCSequence.h"; sourceTree = ""; }; + B7D273091822F4AA0054849B /* CCSequence.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCSequence.m; path = "cocos2d-ui/CCBReader/CCSequence.m"; sourceTree = ""; }; + B7D2730A1822F4AA0054849B /* CCSequenceProperty.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCSequenceProperty.h; path = "cocos2d-ui/CCBReader/CCSequenceProperty.h"; sourceTree = ""; }; + B7D2730B1822F4AA0054849B /* CCSequenceProperty.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCSequenceProperty.m; path = "cocos2d-ui/CCBReader/CCSequenceProperty.m"; sourceTree = ""; }; B7D2730C1822F4AA0054849B /* CCBuilderReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCBuilderReader.h; path = "cocos2d-ui/CCBReader/CCBuilderReader.h"; sourceTree = ""; }; B7E260D618171D2000A0E872 /* CCTextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCTextField.h; path = "cocos2d-ui/CCTextField.h"; sourceTree = ""; }; B7E260D718171D2000A0E872 /* CCTextField.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCTextField.m; path = "cocos2d-ui/CCTextField.m"; sourceTree = ""; }; @@ -1340,11 +1336,9 @@ D23C5CBB194BC500007CA669 /* CCTouchAndroid.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCTouchAndroid.m; path = Android/CCTouchAndroid.m; sourceTree = ""; }; D24160F61958F6EE003673BD /* CCAnimationManager_Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCAnimationManager_Private.h; path = "cocos2d-ui/CCBReader/CCAnimationManager_Private.h"; sourceTree = ""; }; D24160F71958F6EE003673BD /* CCAnimationManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCAnimationManager.h; path = "cocos2d-ui/CCBReader/CCAnimationManager.h"; sourceTree = ""; }; - D24160F81958F6EE003673BD /* CCAnimationManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCAnimationManager.m; path = "cocos2d-ui/CCBReader/CCAnimationManager.m"; sourceTree = ""; }; + D24160F81958F6EE003673BD /* CCAnimationManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; lineEnding = 0; name = CCAnimationManager.m; path = "cocos2d-ui/CCBReader/CCAnimationManager.m"; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.objc; }; D24160F91958F6EE003673BD /* CCAnimationManager+FrameAnimation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "CCAnimationManager+FrameAnimation.h"; path = "cocos2d-ui/CCBReader/CCAnimationManager+FrameAnimation.h"; sourceTree = ""; }; D24160FA1958F6EE003673BD /* CCAnimationManager+FrameAnimation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "CCAnimationManager+FrameAnimation.m"; path = "cocos2d-ui/CCBReader/CCAnimationManager+FrameAnimation.m"; sourceTree = ""; }; - D24160FB1958F6EE003673BD /* CCBAnimationManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CCBAnimationManager.h; path = "cocos2d-ui/CCBReader/CCBAnimationManager.h"; sourceTree = ""; }; - D24160FC1958F6EE003673BD /* CCBAnimationManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCBAnimationManager.m; path = "cocos2d-ui/CCBReader/CCBAnimationManager.m"; sourceTree = ""; }; D24161041958F72B003673BD /* CCEffectRenderer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCEffectRenderer.h; sourceTree = ""; }; D24161051958F72B003673BD /* CCEffectRenderer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CCEffectRenderer.m; sourceTree = ""; }; D24161061958F72B003673BD /* CCEffectSaturation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCEffectSaturation.h; sourceTree = ""; }; @@ -1431,7 +1425,7 @@ D34CAD6519C3A7A5009BED7A /* CCRendererBasicTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCRendererBasicTypes.h; sourceTree = ""; }; D34CAD6819C3A7B3009BED7A /* CCRendererBasicTypes.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CCRendererBasicTypes.m; sourceTree = ""; }; D34CAD6A19C3AA10009BED7A /* CCRendererBasicTypes_Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCRendererBasicTypes_Private.h; sourceTree = ""; }; - D36369D21A1E85DF007EE5FC /* CCDeprecated.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCDeprecated.h; sourceTree = ""; }; + D36369D21A1E85DF007EE5FC /* CCDeprecated.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = CCDeprecated.h; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; }; D36DFA2719996EC500DEC135 /* CCRendererGLSupport.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CCRendererGLSupport.m; path = ../CCRendererGLSupport.m; sourceTree = ""; }; D3737E321A1F130700782024 /* NSEvent+CC.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSEvent+CC.h"; sourceTree = ""; }; D3737E331A1F130700782024 /* NSEvent+CC.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSEvent+CC.m"; sourceTree = ""; }; @@ -2038,7 +2032,7 @@ isa = PBXGroup; children = ( 571CD01A19649E03003D460C /* Platform */, - B7D272FA1822F4920054849B /* CCBReader */, + B7D272FA1822F4920054849B /* CCSBReader */, B7C6237917EA7D8600928F91 /* cocos2d-ui.h */, B78AE45C17E7AF1C0028BE0B /* CCControl.h */, B750162218124B6000708A2F /* CCControlSubclass.h */, @@ -2057,7 +2051,7 @@ name = "cocos2d-ui"; sourceTree = ""; }; - B7D272FA1822F4920054849B /* CCBReader */ = { + B7D272FA1822F4920054849B /* CCSBReader */ = { isa = PBXGroup; children = ( D24160F61958F6EE003673BD /* CCAnimationManager_Private.h */, @@ -2065,22 +2059,20 @@ D24160F81958F6EE003673BD /* CCAnimationManager.m */, D24160F91958F6EE003673BD /* CCAnimationManager+FrameAnimation.h */, D24160FA1958F6EE003673BD /* CCAnimationManager+FrameAnimation.m */, - D24160FB1958F6EE003673BD /* CCBAnimationManager.h */, - D24160FC1958F6EE003673BD /* CCBAnimationManager.m */, - B7D273021822F4AA0054849B /* CCBKeyframe.h */, - B7D273031822F4AA0054849B /* CCBKeyframe.m */, - B7D273041822F4AA0054849B /* CCBLocalizationManager.h */, - B7D273051822F4AA0054849B /* CCBLocalizationManager.m */, - B7D273061822F4AA0054849B /* CCBReader.h */, - B7D273071822F4AA0054849B /* CCBReader.m */, - B7D273081822F4AA0054849B /* CCBSequence.h */, - B7D273091822F4AA0054849B /* CCBsequence.m */, - B7D2730A1822F4AA0054849B /* CCBSequenceProperty.h */, - B7D2730B1822F4AA0054849B /* CCBSequenceProperty.m */, + B7D273021822F4AA0054849B /* CCKeyframe.h */, + B7D273031822F4AA0054849B /* CCKeyframe.m */, + B7D273041822F4AA0054849B /* CCLocalizationManager.h */, + B7D273051822F4AA0054849B /* CCLocalizationManager.m */, + B7D273061822F4AA0054849B /* CCSBReader.h */, + B77060CE18341AD50043CC67 /* CCSBReader_Private.h */, + B7D273071822F4AA0054849B /* CCSBReader.m */, + B7D273081822F4AA0054849B /* CCSequence.h */, + B7D273091822F4AA0054849B /* CCSequence.m */, + B7D2730A1822F4AA0054849B /* CCSequenceProperty.h */, + B7D2730B1822F4AA0054849B /* CCSequenceProperty.m */, B7D2730C1822F4AA0054849B /* CCBuilderReader.h */, - B77060CE18341AD50043CC67 /* CCBReader_Private.h */, ); - name = CCBReader; + name = CCSBReader; sourceTree = ""; }; B7EE69DB1819E73A00B983FE /* Layouts */ = { @@ -2319,7 +2311,7 @@ buildActionMask = 2147483647; files = ( D2DDB09919805E8400233D80 /* CCQuaternion.h in Headers */, - B7D273111822F4AA0054849B /* CCBLocalizationManager.h in Headers */, + B7D273111822F4AA0054849B /* CCLocalizationManager.h in Headers */, 5018F2690DFDEAFF00C013A5 /* CCAction.h in Headers */, 5018F26B0DFDEAFF00C013A5 /* CCNode.h in Headers */, 9DBCA31419B68BE400EFE96D /* CCEffectColorChannelOffset.h in Headers */, @@ -2385,7 +2377,7 @@ D2C788261A5D32C10070EA5D /* CCView.h in Headers */, D34CAD6C19C3AA10009BED7A /* CCRendererBasicTypes_Private.h in Headers */, D268FE13198078FF00ECBCD0 /* CCEffectReflection.h in Headers */, - B7D273131822F4AA0054849B /* CCBReader.h in Headers */, + B7D273131822F4AA0054849B /* CCSBReader.h in Headers */, 9DF37621191C594A00C6D27A /* CCEffectPixellate.h in Headers */, 509D0818101E4FCE007E1749 /* CCTiledMap.h in Headers */, D31C795219994197007921E1 /* CCMetalSupport_Private.h in Headers */, @@ -2393,7 +2385,7 @@ D27451B719AE5517006DA0A1 /* CCEffectDistanceField.h in Headers */, 50CFAC391023660000175934 /* CCTMXXMLParser.h in Headers */, 50316AA610291280003ACFE7 /* CCRenderTexture.h in Headers */, - B7D273171822F4AA0054849B /* CCBSequenceProperty.h in Headers */, + B7D273171822F4AA0054849B /* CCSequenceProperty.h in Headers */, 50316AD41029A126003ACFE7 /* CCMotionStreak.h in Headers */, 83E1A86819C8ACA0000A3BCA /* CCPackageManagerDelegate.h in Headers */, D38058201889CE7700822437 /* CCCache.h in Headers */, @@ -2412,7 +2404,7 @@ 83E1A87919C8ACC1000A3BCA /* CCPackageDownloadManager.h in Headers */, 50D2AC9710E90DFA0068ECEB /* CCTiledMapObjectGroup.h in Headers */, D268FE11198078FF00ECBCD0 /* CCEffectHue.h in Headers */, - B7D273151822F4AA0054849B /* CCBSequence.h in Headers */, + B7D273151822F4AA0054849B /* CCSequence.h in Headers */, D285ECF0192EA92A009F4E88 /* CCGLView.h in Headers */, 5015043B113300F900A9CA65 /* CCActionProgressTimer.h in Headers */, D24161091958F72B003673BD /* CCEffectRenderer.h in Headers */, @@ -2470,8 +2462,7 @@ A003AC8C1657071100C7B792 /* ccFPSImages.h in Headers */, 750530291A54B21F009AEFA8 /* CCScene+Private.h in Headers */, B74C2B9B17BDA63A00A829C0 /* CCSprite9Slice.h in Headers */, - B77060CF18341AD50043CC67 /* CCBReader_Private.h in Headers */, - D24161021958F6EE003673BD /* CCBAnimationManager.h in Headers */, + B77060CF18341AD50043CC67 /* CCSBReader_Private.h in Headers */, B75C2E7C17C5908B002B0E0D /* NSAttributedString+CCAdditions.h in Headers */, A6A0734517C788EB004343C8 /* CCResponderManager.h in Headers */, A6A0734A17C78EF3004343C8 /* CCResponder.h in Headers */, @@ -2484,7 +2475,7 @@ 571CD02619649E03003D460C /* CCPlatformTextFieldAndroid.h in Headers */, B78AE46817E7AF1C0028BE0B /* CCScrollView.h in Headers */, B78AE46C17E7AF6C0028BE0B /* UITouch+CC.h in Headers */, - B7D2730F1822F4AA0054849B /* CCBKeyframe.h in Headers */, + B7D2730F1822F4AA0054849B /* CCKeyframe.h in Headers */, E525FCC2CF72D3667DE4D71B /* CCPackageHelper.h in Headers */, E525F3A2BBCBB446B67D8260 /* CCPackage_private.h in Headers */, E525FF1A60724C91275720C5 /* CCPackageManager_private.h in Headers */, @@ -2667,15 +2658,14 @@ 7A59476719E3731600F65F90 /* CCAnimationManager.h in Headers */, 7A59476919E3731700F65F90 /* CCAnimationManager+FrameAnimation.h in Headers */, D36369D51A1E85DF007EE5FC /* CCDeprecated.h in Headers */, - 7A59476B19E3731800F65F90 /* CCBAnimationManager.h in Headers */, - 7A59476D19E3731800F65F90 /* CCBKeyframe.h in Headers */, - 7A59476F19E3731900F65F90 /* CCBLocalizationManager.h in Headers */, - 7A59477119E3731A00F65F90 /* CCBReader.h in Headers */, - 7A59477319E3731B00F65F90 /* CCBSequence.h in Headers */, - 7A59477519E3731C00F65F90 /* CCBSequenceProperty.h in Headers */, + 7A59476D19E3731800F65F90 /* CCKeyframe.h in Headers */, + 7A59476F19E3731900F65F90 /* CCLocalizationManager.h in Headers */, + 7A59477119E3731A00F65F90 /* CCSBReader.h in Headers */, + 7A59477319E3731B00F65F90 /* CCSequence.h in Headers */, + 7A59477519E3731C00F65F90 /* CCSequenceProperty.h in Headers */, D2C788281A5D32C10070EA5D /* CCView.h in Headers */, 7A59477719E3731C00F65F90 /* CCBuilderReader.h in Headers */, - 7A59477819E3731D00F65F90 /* CCBReader_Private.h in Headers */, + 7A59477819E3731D00F65F90 /* CCSBReader_Private.h in Headers */, 7A59477919E3731D00F65F90 /* cocos2d-ui.h in Headers */, 7A59477A19E3731E00F65F90 /* CCControl.h in Headers */, 7A59477B19E3731E00F65F90 /* CCControlSubclass.h in Headers */, @@ -2698,7 +2688,7 @@ isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( - D2FEB611194F6C9E00FC0574 /* CCBLocalizationManager.h in Headers */, + D2FEB611194F6C9E00FC0574 /* CCLocalizationManager.h in Headers */, D2FEB612194F6C9E00FC0574 /* CCAction.h in Headers */, D2FEB613194F6C9E00FC0574 /* CCNode.h in Headers */, D2FEB614194F6C9E00FC0574 /* CCDirector.h in Headers */, @@ -2754,17 +2744,16 @@ BC9F4EA019DB649E00B25F01 /* CCPackageHelper.h in Headers */, D2FEB648194F6C9E00FC0574 /* CCEffectStack.h in Headers */, D2FEB64A194F6C9E00FC0574 /* CCTextField.h in Headers */, - D2FEB64B194F6C9E00FC0574 /* CCBReader.h in Headers */, + D2FEB64B194F6C9E00FC0574 /* CCSBReader.h in Headers */, D2FEB64C194F6C9E00FC0574 /* CCEffectPixellate.h in Headers */, 14B84C931A700B55002C4D20 /* CCAppController.h in Headers */, - D2FEB64D194F6C9E00FC0574 /* CCActionManager.h in Headers */, D2FEB64E194F6C9E00FC0574 /* CCTiledMap.h in Headers */, BC9F4E9819DB644600B25F01 /* CCPackageManager.h in Headers */, BC9F4E9919DB644900B25F01 /* CCPackageManagerDelegate.h in Headers */, D22907AF1A2F5E440038FF61 /* CCEffectOutline.h in Headers */, D2FEB652194F6C9E00FC0574 /* CCTMXXMLParser.h in Headers */, D2FEB653194F6C9E00FC0574 /* CCRenderTexture.h in Headers */, - D2FEB654194F6C9E00FC0574 /* CCBSequenceProperty.h in Headers */, + D2FEB654194F6C9E00FC0574 /* CCSequenceProperty.h in Headers */, D2FEB655194F6C9E00FC0574 /* CCMotionStreak.h in Headers */, D2FEB656194F6C9E00FC0574 /* CCCache.h in Headers */, D2FEB657194F6C9E00FC0574 /* CCRenderer_Private.h in Headers */, @@ -2782,7 +2771,7 @@ D24161161958F738003673BD /* CCAnimationManager+FrameAnimation.h in Headers */, D27451AB19AD430A006DA0A1 /* CCEffectDropShadow.h in Headers */, D2FEB664194F6C9E00FC0574 /* CCTiledMapObjectGroup.h in Headers */, - D2FEB665194F6C9E00FC0574 /* CCBSequence.h in Headers */, + D2FEB665194F6C9E00FC0574 /* CCSequence.h in Headers */, D2DDB09819805E8400233D80 /* CCMatrix4.h in Headers */, D2FEB667194F6C9E00FC0574 /* CCGLView.h in Headers */, D2FEB668194F6C9E00FC0574 /* CCActionProgressTimer.h in Headers */, @@ -2833,7 +2822,7 @@ D2FEB6A6194F6C9E00FC0574 /* CCSlider.h in Headers */, D2FEB6A7194F6C9E00FC0574 /* ccFPSImages.h in Headers */, D2FEB6A8194F6C9E00FC0574 /* CCSprite9Slice.h in Headers */, - D2FEB6A9194F6C9E00FC0574 /* CCBReader_Private.h in Headers */, + D2FEB6A9194F6C9E00FC0574 /* CCSBReader_Private.h in Headers */, D2FEB6AA194F6C9E00FC0574 /* NSAttributedString+CCAdditions.h in Headers */, D2FEB6AB194F6C9E00FC0574 /* CCResponderManager.h in Headers */, D2DDB09A19805E8400233D80 /* CCQuaternion.h in Headers */, @@ -2847,7 +2836,7 @@ D2FEB6B4194F6C9E00FC0574 /* CCScrollView.h in Headers */, D2C788271A5D32C10070EA5D /* CCView.h in Headers */, D2FEB6B6194F6C9E00FC0574 /* UITouch+CC.h in Headers */, - D2FEB6B7194F6C9E00FC0574 /* CCBKeyframe.h in Headers */, + D2FEB6B7194F6C9E00FC0574 /* CCKeyframe.h in Headers */, E525F42E42D4753126DB7834 /* CCNode+RecursiveDescription.h in Headers */, E525F80E977C3BBE006A6902 /* CCFileUtils.h in Headers */, E525FDDD741BA508C227F090 /* CCFile_Private.h in Headers */, @@ -3087,9 +3076,8 @@ 5038B6B30E196CD8009A621E /* CCParticleSystemBase.m in Sources */, 506602120E38A70D000B500E /* CCScheduler.m in Sources */, D2DDB0A719805E8400233D80 /* CCMatrix3.m in Sources */, - D24161031958F6EE003673BD /* CCBAnimationManager.m in Sources */, 50A07B7B0E4CBCD300AAF0BB /* cocos2d.m in Sources */, - B7D273181822F4AA0054849B /* CCBSequenceProperty.m in Sources */, + B7D273181822F4AA0054849B /* CCSequenceProperty.m in Sources */, D241610F1958F72B003673BD /* CCEffectSaturation.m in Sources */, B7E260D918171D2000A0E872 /* CCTextField.m in Sources */, 50F7B2790F28DE7C00057537 /* CCActionEase.m in Sources */, @@ -3112,7 +3100,7 @@ B7E775D118527EF0004221AA /* CCAppDelegate.m in Sources */, 9DBCA31519B68BE400EFE96D /* CCEffectColorChannelOffset.m in Sources */, D3903B15199528B6003AA81A /* CCMetalView.m in Sources */, - B7D273141822F4AA0054849B /* CCBReader.m in Sources */, + B7D273141822F4AA0054849B /* CCSBReader.m in Sources */, 571CD02B19649E03003D460C /* CCPlatformTextFieldIOS.m in Sources */, 83E1A86519C8ACA0000A3BCA /* CCPackageConstants.m in Sources */, D272032E18FC89A000B100FF /* CCEffectStack.m in Sources */, @@ -3143,16 +3131,16 @@ D268FE0E198078FF00ECBCD0 /* CCEffectBloom.m in Sources */, 9D85671E191B018200573093 /* CCEffectBrightness.m in Sources */, D268FE14198078FF00ECBCD0 /* CCEffectReflection.m in Sources */, - B7D273101822F4AA0054849B /* CCBKeyframe.m in Sources */, + B7D273101822F4AA0054849B /* CCKeyframe.m in Sources */, E0F924721224140400EF2362 /* CCTexture+PVR.m in Sources */, E02BB6D7126CA93A006E46A2 /* CCAnimationCache.m in Sources */, E02BB705126CADEA006E46A2 /* CCAnimation.m in Sources */, E0BC7DA01342CE7B001B4DCC /* CCShader.m in Sources */, A046E29414C1DB7D0005BBF2 /* CCDirectorMac.m in Sources */, A046E29A14C1DB7E0005BBF2 /* CCWindow.m in Sources */, - B7D273121822F4AA0054849B /* CCBLocalizationManager.m in Sources */, + B7D273121822F4AA0054849B /* CCLocalizationManager.m in Sources */, D241610B1958F72B003673BD /* CCEffectRenderer.m in Sources */, - B7D273161822F4AA0054849B /* CCBsequence.m in Sources */, + B7D273161822F4AA0054849B /* CCSequence.m in Sources */, 9DF37622191C594A00C6D27A /* CCEffectPixellate.m in Sources */, A0A7A53D1514F27D00C8BD16 /* CCActionCatmullRom.m in Sources */, D380581B1889AD6000822437 /* CCRenderer.m in Sources */, @@ -3320,14 +3308,13 @@ 7A5948B019E375B900F65F90 /* CCPlatformTextFieldMac.m in Sources */, 7A5948B319E375B900F65F90 /* CCAnimationManager.m in Sources */, 7A5948B519E375B900F65F90 /* CCAnimationManager+FrameAnimation.m in Sources */, - 7A5948B719E375BA00F65F90 /* CCBAnimationManager.m in Sources */, - 7A5948B919E375BA00F65F90 /* CCBKeyframe.m in Sources */, - 7A5948BB19E375BA00F65F90 /* CCBLocalizationManager.m in Sources */, - 7A5948BD19E375BB00F65F90 /* CCBReader.m in Sources */, - 7A5948BF19E375BB00F65F90 /* CCBsequence.m in Sources */, + 7A5948B919E375BA00F65F90 /* CCKeyframe.m in Sources */, + 7A5948BB19E375BA00F65F90 /* CCLocalizationManager.m in Sources */, + 7A5948BD19E375BB00F65F90 /* CCSBReader.m in Sources */, + 7A5948BF19E375BB00F65F90 /* CCSequence.m in Sources */, D39D34A41A4243EE00B5A115 /* CCViewportNode.m in Sources */, 9D03A5F81A02F8C600C651C8 /* CCEffectLighting.m in Sources */, - 7A5948C119E375BB00F65F90 /* CCBSequenceProperty.m in Sources */, + 7A5948C119E375BB00F65F90 /* CCSequenceProperty.m in Sources */, 7A5948C719E375BC00F65F90 /* CCControl.m in Sources */, 7A5948C919E375BD00F65F90 /* CCButton.m in Sources */, 7A5948CB19E375BD00F65F90 /* CCTableView.m in Sources */, @@ -3370,7 +3357,7 @@ D2FEB6CA194F6C9E00FC0574 /* CCParticleSystemBase.m in Sources */, D2FEB6CC194F6C9E00FC0574 /* CCScheduler.m in Sources */, D2FEB6CD194F6C9E00FC0574 /* cocos2d.m in Sources */, - D2FEB6CF194F6C9E00FC0574 /* CCBSequenceProperty.m in Sources */, + D2FEB6CF194F6C9E00FC0574 /* CCSequenceProperty.m in Sources */, D2FEB6D1194F6C9E00FC0574 /* CCTextField.m in Sources */, D2FEB6D2194F6C9E00FC0574 /* CCActionEase.m in Sources */, BC9F4E8E19DB632800B25F01 /* CCPackageConstants.m in Sources */, @@ -3382,7 +3369,6 @@ D2FEB6D6194F6C9E00FC0574 /* CCTMXXMLParser.m in Sources */, D2FEB6D7194F6C9E00FC0574 /* CCSprite.m in Sources */, D2FEB6D8194F6C9E00FC0574 /* CCTiledMap.m in Sources */, - D2FEB6D9194F6C9E00FC0574 /* CCFileUtils.m in Sources */, 14B84C961A700B55002C4D20 /* CCAppController.m in Sources */, D2FEB6DB194F6C9E00FC0574 /* CCTouch.m in Sources */, D2EC6039199D9F82001A15E9 /* CCRendererGLSupport.m in Sources */, @@ -3393,7 +3379,7 @@ D2FEB6DF194F6C9E00FC0574 /* CCParticleSystem.m in Sources */, D2FEB6E2194F6C9E00FC0574 /* CCAppDelegate.m in Sources */, D27451BD19AEC84C006DA0A1 /* CCEffectDistanceField.m in Sources */, - D2FEB6E3194F6C9E00FC0574 /* CCBReader.m in Sources */, + D2FEB6E3194F6C9E00FC0574 /* CCSBReader.m in Sources */, D304BC281A1DA3CA005A0260 /* CCRenderableNode.m in Sources */, BC9F4E9219DB633B00B25F01 /* CCPackageDownloadManager.m in Sources */, D3903B17199528DF003AA81A /* CCRenderDispatch.m in Sources */, @@ -3430,15 +3416,15 @@ D3903B18199528F3003AA81A /* CCEffectBlur.m in Sources */, D2FEB703194F6C9E00FC0574 /* CCEffectBrightness.m in Sources */, D24161171958F738003673BD /* CCAnimationManager+FrameAnimation.m in Sources */, - D2FEB705194F6C9E00FC0574 /* CCBKeyframe.m in Sources */, + D2FEB705194F6C9E00FC0574 /* CCKeyframe.m in Sources */, D2FEB706194F6C9E00FC0574 /* CCTexture+PVR.m in Sources */, D2FEB708194F6C9E00FC0574 /* CCAnimationCache.m in Sources */, D2FEB709194F6C9E00FC0574 /* CCAnimation.m in Sources */, D2FEB70A194F6C9E00FC0574 /* CCShader.m in Sources */, D2FEB710194F6C9E00FC0574 /* CCDirectorMac.m in Sources */, D2FEB712194F6C9E00FC0574 /* CCWindow.m in Sources */, - D2FEB714194F6C9E00FC0574 /* CCBLocalizationManager.m in Sources */, - D2FEB719194F6C9E00FC0574 /* CCBsequence.m in Sources */, + D2FEB714194F6C9E00FC0574 /* CCLocalizationManager.m in Sources */, + D2FEB719194F6C9E00FC0574 /* CCSequence.m in Sources */, D2FEB71A194F6C9E00FC0574 /* CCEffectPixellate.m in Sources */, D2FEB71B194F6C9E00FC0574 /* CCActionCatmullRom.m in Sources */, D2FEB71D194F6C9E00FC0574 /* CCRenderer.m in Sources */, diff --git a/cocos2d/CCDeprecated.h b/cocos2d/CCDeprecated.h index 4cbe338e981..371ac5955ac 100644 --- a/cocos2d/CCDeprecated.h +++ b/cocos2d/CCDeprecated.h @@ -29,7 +29,10 @@ #import "CCNode.h" #import "CCTexture.h" #import "CCAction.h" +#import "CCSBReader.h" +// ease backwards compatability for the old class, which was just "CCBReader" +@compatibility_alias CCBReader CCSBReader; /** RGB color composed of bytes 3 bytes */ @@ -436,3 +439,17 @@ enum { @property (nonatomic, readwrite, assign) NSInteger tag; @end + + +@protocol CCSBReaderDidLoadDeprecated +@optional +/** + Use didLoadFromSB instead. + */ +- (void) didLoadFromCCB __attribute__((deprecated)); + +@end + +@interface CCNode(CCSBReaderDeprecated) + +@end diff --git a/cocos2d/Platforms/Android/CCActivity.m b/cocos2d/Platforms/Android/CCActivity.m index 03b12a114ac..1cbc9ef34ce 100644 --- a/cocos2d/Platforms/Android/CCActivity.m +++ b/cocos2d/Platforms/Android/CCActivity.m @@ -16,7 +16,7 @@ #import #import "cocos2d.h" -#import "CCBReader.h" +#import "CCSBReader.h" #import "CCGLView.h" #import "CCScene.h" diff --git a/cocos2d/Platforms/CCAppController.h b/cocos2d/Platforms/CCAppController.h index eff3bda9cb4..a12ee022a3e 100644 --- a/cocos2d/Platforms/CCAppController.h +++ b/cocos2d/Platforms/CCAppController.h @@ -131,7 +131,7 @@ /** Instantiate and return the first scene in the application - Only override this if you wish to load something other than a `.ccb` file + Only override this if you wish to load something other than a `.sb` file (i.e. a programaticaly created CCScene instance) */ - (CCScene*) createFirstScene; diff --git a/cocos2d/Platforms/CCAppController.m b/cocos2d/Platforms/CCAppController.m index 2f4bf992c18..b08930a5411 100644 --- a/cocos2d/Platforms/CCAppController.m +++ b/cocos2d/Platforms/CCAppController.m @@ -10,7 +10,7 @@ #import #import "CCAppController.h" #import "CCScene.h" -#import "CCBReader.h" +#import "CCSBReader.h" #import "CCDeviceInfo.h" #import "CCAppDelegate.h" #import "OALSimpleAudio.h" @@ -75,12 +75,12 @@ - (void)setupApplication */ - (CCScene *)createFirstScene { - return [CCBReader loadAsScene:self.firstSceneName]; + return [CCSBReader loadAsScene:self.firstSceneName]; } - (CCScene *)startScene { - NSAssert(_glView.director, @"Require a valid director to decode the CCB file!"); + NSAssert(_glView.director, @"Require a valid director to decode the SB file!"); [CCDirector pushCurrentDirector:_glView.director]; CCScene *scene = [self createFirstScene]; @@ -104,7 +104,7 @@ - (NSDictionary*)iosConfig // Fixed size. As wide as iPhone 5 at 2x and as high as the iPad at 2x. config[CCScreenModeFixedDimensions] = [NSValue valueWithCGSize:CGSizeMake(586, 384)]; - [CCBReader configureCCFileUtils]; + [CCSBReader configureCCFileUtils]; return config; } @@ -216,7 +216,7 @@ - (void)setupFixedScreenMode:(NSDictionary *)config director:(CCDirector *)direc - (NSDictionary*)androidConfig { - [CCBReader configureCCFileUtils]; + [CCSBReader configureCCFileUtils]; NSString* configPath = [[[NSBundle mainBundle] resourcePath] stringByAppendingPathComponent:@"Published-Android"]; @@ -353,7 +353,7 @@ -(CGSize)defaultWindowSize - (NSDictionary*)macConfig { - [CCBReader configureCCFileUtils]; + [CCSBReader configureCCFileUtils]; NSMutableDictionary *macConfig = [NSMutableDictionary dictionary]; diff --git a/cocos2d/cocos2d.h b/cocos2d/cocos2d.h index a12f6f126a1..5f9126478e2 100644 --- a/cocos2d/cocos2d.h +++ b/cocos2d/cocos2d.h @@ -44,7 +44,6 @@ #define COCOS2D_VERSION 0x00030403 #define COCOS2D_BUILD @"develop" - #import "ccConfig.h" #import "ccTypes.h" @@ -154,6 +153,7 @@ #import "NSEvent+CC.h" #import "CCDeprecated.h" #import "CCScheduler.h" +#import "CCSBReader.h" // UI #import "cocos2d-ui.h" diff --git a/external/ObjectAL b/external/ObjectAL index 547d0795d9b..9cc7bdce6f3 160000 --- a/external/ObjectAL +++ b/external/ObjectAL @@ -1 +1 @@ -Subproject commit 547d0795d9b9284f98c0079c53ece4d96d934a2e +Subproject commit 9cc7bdce6f303c1e6a595b25a2ebc8c814e597ec