Skip to content

Commit d61c292

Browse files
committed
update -ext
1 parent 3a938d8 commit d61c292

File tree

4 files changed

+15
-10
lines changed

4 files changed

+15
-10
lines changed

cocos2d-ext/CCBReader/CCAnimationManager.m

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
#import "CCBKeyframe.h"
3232
#import <objc/runtime.h>
3333

34-
#import "CCDirector_Private.h"
34+
#import "CCDirector.h"
3535
#import "CCBReader_Private.h"
3636
#import "CCActionManager.h"
3737

@@ -248,7 +248,7 @@ - (CCActionInterval*)actionFromKeyframe0:(CCBKeyframe*)kf0 andKeyframe1:(CCBKeyf
248248
}
249249
}
250250
#endif
251-
} else {
251+
else {
252252
CCLOG(@"CCBReader: Failed to create animation for property: %@", name);
253253
}
254254

cocos2d-ext/CCBReader/CCBReader.m

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,11 @@
3333
#import "CCBKeyframe.h"
3434
#import "CCBLocalizationManager.h"
3535
#import "CCBReader_Private.h"
36-
#import "CCNode_Private.h"
37-
#import "CCDirector_Private.h"
36+
#import "CCNode.h"
37+
#import "CCDirector.h"
38+
#if CC_PHYSICS
3839
#import "CCPhysics+ObjectiveChipmunk.h"
40+
#endif
3941
#import "CCAnimationManager_Private.h"
4042
#if CC_EFFECTS
4143
#import "CCEffectStack.h"
@@ -1165,6 +1167,7 @@ -(void)postDeserialization
11651167
}
11661168
}
11671169

1170+
#if CC_PHYSICS
11681171
-(void)readJoints
11691172
{
11701173
int numJoints = readIntWithSign(self, NO);
@@ -1175,10 +1178,8 @@ -(void)readJoints
11751178
}
11761179
}
11771180

1178-
11791181
-(void)readJoint
11801182
{
1181-
11821183
CCPhysicsJoint * joint = nil;
11831184
NSString* className = [self readCachedString];
11841185

@@ -1320,7 +1321,7 @@ -(void)readJoint
13201321
[joint resetScale:NodeToPhysicsScale(nodeBodyA).x];
13211322

13221323
}
1323-
1324+
#endif
13241325
-(CCNode*) nodeFromClassName:(NSString*)nodeClassName
13251326
{
13261327
Class nodeClass = NSClassFromString(nodeClassName);
@@ -1521,6 +1522,7 @@ - (CCNode*) readNodeGraphParent:(CCNode*)parent
15211522

15221523
animatedProps = NULL;
15231524

1525+
#if CC_PHYSICS
15241526
// Read physics
15251527
BOOL hasPhysicsBody = readBool(self);
15261528
if (hasPhysicsBody)
@@ -1645,7 +1647,7 @@ - (CCNode*) readNodeGraphParent:(CCNode*)parent
16451647
//#endif
16461648

16471649
}
1648-
1650+
#endif
16491651
// Read and add children
16501652
int numChildren = readIntWithSign(self, NO);
16511653
for (int i = 0; i < numChildren; i++)
@@ -1809,7 +1811,10 @@ - (CCNode*) readFileWithCleanUp:(BOOL)cleanUp actionManagers:(NSMutableDictionar
18091811
actionManagers = am;
18101812

18111813
CCNode* node = [self readNodeGraphParent:NULL];
1814+
1815+
#if CC_PHYSICS
18121816
[self readJoints];
1817+
#endif
18131818
[self postDeserialization];
18141819

18151820
[actionManagers setObject:self.animationManager forKey:[NSValue valueWithPointer:(__bridge const void *)(node)]];

cocos2d-ext/CCChipmunkPhysics/CCPhysicsBody.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727

2828
#import "CCPhysicsBody.h"
2929
#import "CCPhysics+ObjectiveChipmunk.h"
30-
#import "CCNode_Private.h"
30+
#import "CCNode.h"
3131

3232

3333
@interface CCNode(Private)

cocos2d-ext/CCChipmunkPhysics/CCPhysicsJoint.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424

2525
#import "CCPhysicsJoint.h"
2626
#import "CCPhysics+ObjectiveChipmunk.h"
27-
#import "CCNode_Private.h"
27+
#import "CCNode.h"
2828

2929
@interface CCNode(Private)
3030
-(CGAffineTransform)nonRigidTransform;

0 commit comments

Comments
 (0)