Tuesday, May 18, 2010

Retrospective: Week Fourteen

‹prev | My Chain | next›

In an ongoing effort to make this chain as valuable as possible to myself (and possibly others), I perform a weekly retrospective of how the past week went (notes from last week). I do this on Tuesdays to avoid conflicts with B'more on Rails, which usually holds events then.

This week (like the week before), I continue working on my (fab) game—a game inspired by the fab.js framework that I am writing for my kids.


  • I played tag with my son in my (fab) game. I was quite excited to have gotten the game to this point already.
  • Figured out how to broadcast to many fab.js clients
  • Started playing with raphaël.js
    • Very nice / easy to pick up framework.
    • Needed to reach under the API covers (to stop animation). That's something of a not-so-well, but the Raphaël code is so well organized that it was easy to accomplish what I wanted.
  • Refactored a fab.js unary into a binary with relative ease, using that to support a backend player list. The code was prettier as well!


  • Still not testing my javascript.
  • Had not separated my Room/Player concerns as well as I hoped. Switching from <canvas> to Raphaël forced changes such that the Room, which had been watching the Player move, now moves the Player and informs the Player where it is. This required a fair number of changes in my code. I wonder if it possible to have coded this such that fewer changes were required—less coupling between the two would be a good thing.
  • I struggled with setting the comet iframe's src more than I should have. I was sure that I needed to muck with the window.location inside the iframe. It took me much longer than it should have to figure out that I could simply set the src attribute directly.


  • I am having way too much fun playing around with these Javascript frameworks. That is certainly a good thing, but I do ultimately want to produce robust, accurate, maintainable code. That means testing. I must test!
  • I am not sure if it is possible to detect disconnecting clients in fab.js. Worth some time to investigate.
  • Regardless of the answer to the above, I ought to be able to add client heartbeats to passively remove players from the room.

Day #107

No comments:

Post a Comment