Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options answers only not deleted user 29746

iOS is an operating system for mobile devices created by Apple Inc. It runs on the iPhone, iPad, and iPod touch.

0 votes
Accepted

IOS very simple 2d engine/api rendering showdown

The options provided are unsuitable to the task you've described. Apple has created a framework that works very, very well for 2-dimensional games called SpriteKit To be precise: Core Animation and …
Attackfarm's user avatar
  • 2,209
2 votes
Accepted

Swift - Why does my SKShapeNode pass through an object, pausing briefly beforehand?

You are not applying a force or a velocity to the ball. Rather, you're simply changing the position. If the tilt is small, it doesn't move much, and is thus stopped by the physics simulation. If th …
Attackfarm's user avatar
  • 2,209
0 votes
Accepted

Sprite Kit - keeping character level with the terrain 2d endless runner

To keep a character level with a moving "ground" without its x position being affected by the physics engine, it would seem the best solution might be to place an SKConstraint on the character. Speci …
Attackfarm's user avatar
  • 2,209
0 votes
Accepted

How to create a line that is always connected to two Objects. (iPhone, Cocos2d)

To draw a line: https://stackoverflow.com/questions/691648/how-to-draw-a-line-with-cocos2d-iphone To have it follow two points, simply keep track of the desired start and end points, and draw the li …
Community's user avatar
  • 1
2 votes
Accepted

SpriteKit - How to jump to specific position?

SpriteKit uses SKAction objects to accomplish most of its functionality. What you're seeking is SKAction's followPath:duration: action. The following accomplishes this: UIBezierPath *path = [UI …
Community's user avatar
  • 1
1 vote

Spritekit - gradually apply force vector in different direction (space ship turning)

First, the behavior you're describing is that of an aerodynamic vehicle with a single vector of force. A spaceship, flying in space, would operate in an entirely different manner. If this is sti …
Attackfarm's user avatar
  • 2,209
1 vote

Swinging a sword in Xcode with Sprite Kit

I think most of your problems might be solved by understanding the use of category masks. Simply set the masks to ignore contact and collision between the sword and player categories. Specifically, …
Attackfarm's user avatar
  • 2,209
0 votes

Sprite Kit - containsPoint for SKPhysicsBody?

The simplest means of determining if there is contact after your touches finish is to alter the category of the "ball" to a category that registers contacts with the "bucket". That is to say, your …
Attackfarm's user avatar
  • 2,209
6 votes
Accepted

How to detect collision on specific part of the sprite node

Remember that SpriteKit's physics system is based on "SKPhysicsBody"s, which are added to "SKSpriteNode"s. Those physics bodies, however, needn't be attached to visible nodes. The simplest method is …
Attackfarm's user avatar
  • 2,209
2 votes

How should I structure my code to add enemies?

If the only difference between the enemies are sprite changes and simple quantities (number of shots fired, rate of fire, etc), multiple classes would not be needed. This is exactly the sort of game …
Attackfarm's user avatar
  • 2,209
3 votes
Accepted

iOS Sprite Kit - Blend Mode Effect

Wrapping the SKEmitterNode in an SKEffectNode allows the EmitterNode to be rendered into a framebuffer which is subsequently rendered onto the screen. I tested this out (after much push and pull of d …
Attackfarm's user avatar
  • 2,209