Xcode 6 Sprite kit - How to implement "initwithsize"

I am relatively new to SpriteKit and have encountered some problems since upgrading to Xcode 6.

Initially, when I created the projects, I introduced any methods into "initWithSize".

-(id)initWithSize:(CGSize)size {    
if (self = [super initWithSize:size]) {  


}
return self;
}

When starting a project in Xcode 6, this no longer looks like the default value and is instead replaced with:

-(void)didMoveToView:(SKView *)view {}

When I try to apply initwithsize, it just does not work or does not load the sprite objects that I insert into it. Even when you try to create new files, the .m and .h files are no longer presented to me. I have a choice of other options, none of which is .h / .m.

So, 1) How to continue coding, as I did earlier with initwithsize? 2) What to do with creating new files, can I no longer create .m / .h classes?

.

+4
1

, , Xcode. , initWithSize:, unarchiveFromFile: (, GameViewController.m). - initWithSize: . initWithCoder.

- (instancetype)initWithCoder:(NSCoder *)aDecoder
{
    self = [super initWithCoder:aDecoder];

    if (self) {
        // stuff
    }

    return self;
}

, , Xcode 6. , , /etc.

+3

All Articles