I noticed that in the Sprite Kit the coordinate system is upside down.
For example, here is SKSpriteNode:
SKSpriteNode *car = [SKSpriteNode spriteNodeWithImageNamed:@"car"]; car.position = CGPointMake(0, 0); [road addChild:car];
The car is positioned in the center of its parent.
When I set the position:
car.position = CGPointMake(-50, 0);
then it is positioned more to the left. But when I want to move it and increase Y, it moves up!
car.position = CGPointMake(-50, 20);
In UIKit, increasing Y always means that something is moving down. It seems more logical to me. Is there a way to flip the coordinate system in the Sprite Kit?
sprite-kit skspritenode
openfrog
source share