As noted by my previous post, I have a MiniCity. Anyway, I talked about my cute little card thing which generally shows the stats of the city. That’s quite cool, considering I finally managed to get my card automatically updated every so often.
What I didn’t mention was the other side to it. The link.
Every so often, much sooner than the image generation, my link gets the stats and decides what’s important. Then it will bounce to that particular area until the next generation when it’ll decide again. Basically I stick the same link with the card, but when clicked on depending on certain criteria it could go anywhere for the minicity.
So it may decide to increase transport, or industry, or population. I need to tweak it slightly so it doesn’t offer other’s too soon, but it’s pretty neat.
It, along with my image generation script, write the status and update to a email queue script I wrote, which once a day sends me an email summarising the actions. This I like as it means the actions are all there listed, I can see what was linked to, whether or not the image was successfully generated ect…
I’m hoping to expand on my mail queue for other automated tasks. That way I only get one email instead of many. Trust me, many are annoying.
I might tweak the image generation code to include my current rank, then I might just make the image code publicly available for anyone who wants it. It’ll be crude, and it’ll have to be tweaked to get it working for anyone else, but it does the trick for me.
I did try using complicated feed parsers found online, but in the end I used my own basic cURL and expressions to parse the XML.


Recent Comments