I was wondering how you could add a border using the SKView method, I tried initwithsize but did not like it. My actual code for a border is:
self.physicsBody = [SKPhysicsBody bodyWithEdgeOfLoopRect:self.frame.size];
self.physicsBody.Dynamic = NO;
When I enter the code the border for the bottom works but the sides still allow objects to pass through them? Is there a way to fix that? Or should I delete my code and try initwithsize?
Try this code instead:
To get a little more familiar with physics bodies, you should read the docs on this issue to help you in the future.