Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Today’s Extension Using SpriteKit

I'm trying to make a widget game, is it possible to use SpriteKit within a Today Extension?. I've been searching for similar posts but I've only found a question related to using SpriteKit in a AppleWatch extension.

like image 757
neney Avatar asked May 25 '26 11:05

neney


2 Answers

I also working on some game in the today screen. So far I have found 3 solutions which working solid:

  1. Like mentioned working with UIKIT
  2. Use SpriteKit in a minimal way
  3. Using offscreen images for rendering

The problem on solution 2 is, that it's very unreliable. Even calling regularly completionHandler!(NCUpdateResult.newData) has not worked. So it's just the limited usage of SKAction at the end which has bring a lot.

Solution 3 is also good and works quite solid. Of course you must reinvent the wheel and can not use the nice features of SpriteKit. But because I've used this approach already in watchOS games, it was not much effort to use in Extensions.

I recommend solution 3 because you have full control and it works solid.

like image 113
roger Avatar answered May 27 '26 04:05

roger


It is definitely possible. I think you are aiming to build something like the popular "Steve" Widget Game, and I believe that is a SpriteKit Game built into a Today Extension.

To begin, I would suggest to fully understand Today Extensions and it's limits and then fully understanding SpriteKit and the limits that it has.

Something you really want to focus on is making an extremely efficient piece of app. All around, from the actual code and how your code runs. This is due to the fact that Today Extensions are not really apps but "extensions" to your device so if you have a game that is graphics intensive or memory intensive, your app will crash.

like image 33
R S Avatar answered May 27 '26 05:05

R S



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!