Sunday, August 17, 2008

Day 218: Re-port

Today's major task was to port Kuiper from the old 3.0 codebase to the currently developed Rubygame 2.4. This seems to have gone off without any problems, with the exception that I'd made a number of changes to the 3.0 codebase (mouse wheel support, etc) that hadn't been backported yet.

Well, I'm not a Rubygame developer for no reason, so I went and backported them myself. As alluded to earlier, I'm starting to use Git, and it turns out that you don't even have to be an official developer to make changes to Rubygame if you're going the Git route. Instead, you fork the github Rubygame project, make changes to that, and send a 'pull request' back. If you didn't understand any of what I just said, feel better knowing that I didn't really either. I'll have to wait and see if I did it right :)

So on that list, three of the four things I mentioned I wanted to do have mostly been done. I just need to make a little more balance for the tutorial, and then I'm doing a preview release!

The following are the notes I made to myself on the porting process, so later when I need to re-port the game to Rubygame 3.0, I remember what I had to change. You can safely ignore these:


  • Had to change the screen portion of engine to use 'or's instead of an array

  • Put support in 2.4 for key repeats

  • Put support in 2.4 for mouse wheel

  • Fixed bug in ftor new_from_to

  • text.rb keyTyped used symbols, changed to Rubygame::K_*

  • Options.rb, change symbols there to Rubygame::K_*

  • Clock.wait uses milliseconds, Clock.tick returns milliseconds

  • mouseUp in state used symbols, replace with Rubygame::*

  • Change emergency hooks from syms to Rubygame::K_*

  • Change unit tests to use constants instead of syms

  • Map::update used syms for arrow-key movement

No comments: