R3D1: Let's do it again! Last October I started R3, but hardware problems killed it. Problem solved, and I want to share what I'm working on. This one's from the road, style!

Currently: Writing reducer tests for my dungeon crawler.

R3D2: Oof, this is tedious. Over the past few weeks, I got ahead of myself and wrote a bunch of code without tests. However, today I bumped it up to around 50% coverage.

R3D3: More testing. I use @PrettierCode@twitter.com in my project and updated my .prettierrc to enforce trailing commas when ES5-valid. Dangling commas are ugly but simplify git diffs and commit logs.

R3D4: Mostly out of pocket today, but I added a few more tests! I think I've got to follow TDD in the future because writing unit tests, though not the fun part, provides so much clarity.

R3D5: Spent a few hours coding at a wonderful @gusto_official@twitter.com cafe in Naha, Okinawa. Good food, free wifi, outlets at every booth, and... self-serve coffee and tea! 😍

R3D6: Trying to figure out how to write good tests for recursive and/or probabilistic functions.

R3D7: My goal in adding @fbjest@twitter.com tests was to make it easier to keep track of breaking changes. I now have 104 fairly thoughtful tests in 21 suites, yielding ~67% overall coverage. This is a big project for me, but tests are (helpfully!) starting to fail.

R3D9: Yes! My dungeon crawler's player character can pick up items from the ground, select, and use them.

R3D10: Explored some Buddhist temples in northern Thailand, thinking of reducing my application's dependencies to increase its stability in diverse environments, reducing suffering. Refactored for 3 hours. Coming up with better analogies.

R3D11: My player character looks like she has different items equipped when I change weapons. I have some specific user stories to get to next, but I'd really rather fix the animations...

R3D12: I introduced a boss on level 3 of my dungeon crawler. Watch out, he's got Golden Armor and a Dragon Trident, and he knows how to use them! CSS enables great attack animations.

R3D12: Corrected player attack animations to be appropriate (slash, thrust) for the weapon type. Considering what to do about missing art. I'll probably leave it for now and focus on improving the UI for a while.

R3D13: Not altogether pleased to have ejected from create-react-app today. However, I need variable-based keyframe values for my animations, which means I need to be able to access my webpack config to set up SCSS.

D3D14: Having trouble prioritizing... there's so much to do! I think I will spend the next few hours separating components from containers. Later, I'm to have a drink with some folks in Chiang Mai.

R3D15: Finding ways to streamline my code now that I’ve reorganized it into clearer presentational and container components.

R3D16: Added gold as potential loot for my dungeon crawler hero to gather. It doesn’t do anything atm, but every dungeon needs coins.

R3D17: Enemy attacks are animated! Unfortunately, the animation is all or nothing. If one orc adjacent to the player attacks, the other orcs across the map take a swing at nothing in particular.

R3D18: Planning a few fixes and to consolidate two similar components. Haven’t had time to fully implement yet, but my approach makes perfect sense in my head and should definitely work.

R3D19: My hunch yesterday was basically right: enemies now attack separately, and it's marvelous. I also updated some tests and noticed that one "passing" suite didn't even attempt to test the correct function. ¯\_(ツ)_/¯

R3D20: My dungeon crawler is loosely a rescue mission, and I added the kidnapped prince today. He was scantily dressed at first but now has proper trousers, shirtsleeves, and a vest. I haven't decided if his personality is noble or annoying yet.

R3D21: So much sweet delight trying to figure out why my code *works* on the page while failing basic tests. I still have no clue! 🙃

R3D22: I fixed the problem from yesterday. I think it was due to lodash _.clone() being a shallow clone of my array, but I don't know why that was problematic in this case and not anywhere else.

R3D23: Enemies are about to start chasing the player character around the screen. Right now they just individually console.log things like "I should move north!" when the player is north of them. It's cute.

Sign in to participate in the conversation
Social Nasqueron

Nasqueron is a budding community of creative people, writers, developers and thinkers. We focus on free culture, ethics and to be a positive change. We share values like respect, justice and equity.