swift - Failed to load a scene from an sks file -


i have sks file containing scene (gamescene class), , implemented initwithcoder: in gamescene. i'm trying load scene in controller way:

let file = nsbundle.mainbundle().pathforresource("gamescene", oftype: "sks")! if let scene = nskeyedunarchiver.unarchiveobjectwithfile(file) as? gamescene  {...} 

but block never executed , initwithcoder: never called.


Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

java - No use of nillable="0" in SOAP Webservice -

ubuntu - Laravel 5.2 quickstart guide gives Not Found Error -