Enter the Skyrim Alchemy Sage
Welcome fellow Skyrim alchemists – interested in brewing the most potent of poisons?! The most proverbial of potions?!! The most electrifying of elixirs?!!! …perhaps with a touch of alliteration? Hrmph! I have a scroll called the Skyrim Alchemy Helper that will help you craft the finest concoctions – far beyond the skills of mere mortals… In a land where everything’s for sale, this one is free…
Back to Reality
Whew! Ok, now that the RP’er in me has had a chance, the developer in me has a question for you: have you ever been doing something where you just wished you could tie a few things together quickly? Make sense of large amounts of data in no time? Then call me Mr. Rinse & Repeat, ’cause I can’t stop! heh ok… I’ll calm down.
Anyway, as a developer, I have the advantage of being able to put data together and display it in a fashion that makes sense to me. This is a story about one such helper that I made to assist in all my alchemy endeavors in Skyrim – one that I thought I would use as an example (and advertisement) of code that’s good enough for now and why that too can be ok.
The Pain Point of Inspiration
Recently (well, recent to me), Bethesda Game Studios came out with a freshly revamped Skyrim – Special Edition – full of high res textures, bug fixes, and many improvements. Cool! I’ve sunk a few hours in that game, but it’s been a minute and I wouldn’t mind returning to Skyrim to slay some dragons once more!
I get started and it dawns on me: “Geez, I wish I could get back to crafting my alchemy stuff.” I used to have those recipes memorized! What parts for my paralysis poisons? What’s good for restoring health? What’s the other thing I used to craft for those times when I need that thing?!! Blah! It’s too much to get started all over again!
So what’s the solution you might be asking? The new hotness in web frameworks, CI/CD pipelines, and the latest, most feature rich, spanky IDE?! Huh huh huh?!! =D
Hell no! I ain’t got time for that! I made a few hacky scripts to make sure my alchemy prowess was better than ever so I could get back to the game! Pshhh.. what, is this your first rodeo with Skyrim?
Enter the Lazy Dev Sage
So why is this article under filed under “Code”? I realize the quality of the code in these is more or less not ideal… Not a great start for the Code category. Yet, if there’s one thing I know, it’s the tendency of developers (especially jr. devs) to be paralyzed by the quality of their code to the point where progress is painfully slow. This is my effort to say “Heck with it! I need this now!” and to show that even when you write mediocre, unreadable, and/or unmaintainable code… there’s a place for that too.
Going back to one of my favorite rules of the dev process: “Make it work; Make it right; Make it fast”. Right now, we’re at stage 1… I might not ever need to come back to this code, so while it works, it’s fine as it is – and now I can focus on the next task at hand way sooner than perfection would allow for.
Can improvements be made? Hell yes.
Can features be added? Sure – might have to start thinking about the overall architecture if we’re working on this a lot.
Is it fast? Probably not as fast as it could be yet not unbearably slow. Does the trick, I guess scratches head.
Resultant Results and a Few Caveats
For now – it IS… which is way better than “it is not”. I think that counts for something too. Sure: take feedback from code reviews with respect and perspective. Sure: this isn’t how you should be writing code for mission critical applications (sidenote: if your mission critical software doesn’t already have a CI/CD pipeline to prevent this – HOW ARE YOU LIVING YOUR LIFE RN?!! IS IT BROKE? ARE YOU SURE? ASK GARY AND MAKE SURE! I DON’T CARE – ASK HIM AGAIN! WELL WAKE HIM UP!!!)
heh. I’m a dork.
…and sure: is this the standard I want all my code to sink to? Nahh… but for what it is – it’s just right and that’s ok.
If Source Code Wore Underpants
As it turns out, I even went as far as to make a script that allows you to look at the files and their source code! Yeesh! What was I thinking?! Eh… I was having fun banging out something I wanted to make and not thinking twice about it.
So, without further adieu, if you’d like to see London and you’d like to see France – here’s the Skyrim Helper Scripts underpants. They’re hacky and look like hell, but it’s way better than having to relearn all the different alchemy recipes from scratch again!
I hope it helps and I hope you enjoy!
Cheers!
Ryan