ios - Using swift and spriteKit how can I rotate SKSpriteNode around the point outside of node? -
How can I rotate the node in a spreadsheet near an arbitrary point?
I already create an answer "SKNode and position your position in the center of rotation. The node should rotate as a child around the center of the center node. The desired offset (i.e. radius , X + 100), position the position of the hair node in the center of the rotation of the center node to rotate the hair node around the center point. The Cocos 2D works only for the BTD "
But I do not really understand how to write it in code :( I am starting very soon and it seems very difficult. Can anyone help me with code? <
I did it after a few hours of use.
var : SsprintNode = Ssprintnode (Image Named: "Fish") Fish. Chart Point = CP point (X: CGFloat (-0.5), Y: CGflat (-0.2)) Fish .ZPosition = CGflow (Y + 0.5) Fish. Bollyz = CP point (X: CGFLOT (X), Y: CGF Loat (-60-96 * (y-3)) UP = SACAction. ROTEngel (CGFLOT (3.14), Duration: NSTEEnterval (1) fish. Rain Action (Jump)
Comments
Post a Comment