0
나는 chipmunk를 사용하지 않지만 PhysicsEngine, cocos 2d v3 만 사용합니다.CCPhysicsBodyTypeStatic 작동하지 않음
_physicsNode = [CCPhysicsNode node];
_physicsNode.collisionDelegate = self;
_physicsNode.gravity=ccp(0,-165);
_physicsNode.debugDraw = TRUE;
[self addChild:_physicsNode];
CCNode *handAttachPoint=[CCNode node];
handAttachPoint.physicsBody.type=CCPhysicsBodyTypeStatic;
handAttachPoint.position=ccp(self.contentSize.width/8,self.contentSize.height/2);
handAttachPoint.physicsBody = [CCPhysicsBody bodyWithCircleOfRadius:1.0 andCenter:handAttachPoint.anchorPointInPoints];
//[email protected][];
[_physicsNode addChild:handAttachPoint];
나는 handAttachPoint 창에서 정적 노드를 원하는,하지만 여전히 아래로 떨어지고있다 .. :(
어떤 도움에 감사드립니다!
감사합니다. 작동합니다! :) –