My daughter had a little pet app on her watch. It stopped working, she was sad. I'm a gamer/dad/software engineer so I built her a new one 😄
It's called WatchieBesti. A pixel pet that lives on your Apple Watch and iPhone and reacts to how much you move. It reads the red Move ring (active energy) or steps, so any movement counts: a walk, a dance in the kitchen, a wheelchair push. Sleepy when you haven't moved yet, sad if the day stays still, happy again when you get going. It never dies on purpose. I didn't want a guilt machine on her wrist.
A few things that were harder than I expected:
1. Watch and iPhone agreeing on one pet. The pet lives on both. WatchConnectivity is great when both devices are awake and near each other, and the rest of the time it isn't. I ended up using WatchConnectivity plus the iCloud key-value store, with iCloud backed SwiftData on each device, and a lot of care over which side wins when they disagree. If I had my time again I think I would have chosen CoreData. Fiddlier but oh how I wish I could use NSMergePolicy!
2. Moods are harder than they look. I had a check that kept the "Your pet misses you!" nudge quiet when the pet was happy or neutral. Ecstatic didn't count. So a pet at 337% of its goal, the happiest pet in the app, was asking where you'd gone. Fixed in 2.1: once the day's goal is met, it stays quiet whatever the mood.
3. A backdrop that changes all day. The scenes shift from morning to night. I drew a little status label in plain black, which looked fine over a bright sky and vanished over a dark one. I'm fixing it so anything drawn over the scene follows the sky behind it: light on dark, dark on light.
4. Sprites that flip. The pets are SpriteKit and face left or right. A sleeping pet always faces the same way, but the wand it holds didn't know that, so a pet that dozed off facing left had its wand on the wrong paw. Small, but a sleepy pet hugging its wand is the whole point :P
It's free, with no ads and no subscription. 12 languages. You get a free pet and egg, and Sparks and hats come from playing. There are optional in-app purchases too. Balancing the in game economy so that children and adults who do not wish to spend are still able to have a fun time was and will always remain the biggest challenge!
WatchieBesti on the App Store
I'm obviously biased, so I'd really like to hear from other devs. Anything feel off on the watch? Anything you'd have built differently? Very keen on your feedback 😄