My First Contribution

When I was 7 there was this game I played all the time at home and in computer labs when I had the chance at school called RuneScape. So many hours have been poured into this game that I can answer nearly any question about it like I’m a walking encyclopedia, but, as time went on the game got updated in ways that many players didn’t like, including me and so I stopped playing. But in 2013 they reverted all of the changes they made bringing the game back to its original 2007 form calling it “Old School RuneScape” and I started playing again in late 2017 and was having a blast. Around these times there were custom clients circulating for the game which many players used, none of which sadly were open source… until Runelite appeared. Runelite was amazing as it performed the best compared to all clients had hundreds of players developing custom plugins that would improve game play while providing quality of life improvements. One of these plugins are what I contributed to earlier this week in fact. 🙂

In RuneScape your character has an inventory with 28 slots where you carry your items/food/equipment etc. something like this:

Some players wanted the ability to quickly identify items in their inventory so a player created a plugin to create custom sprites that would give items outlines like so:

As I was looking for an issue one player reached out by creating an issue saying that they had poor eyesight and even with the outline they had trouble with identifying items in their inventory and proposed that they would like to be able to fill the entire sprite with the colour and have an opacity slider for the fill colour. I thought I would be able to help so I took a look at Runelite’s wiki to see what they expect from contributors and read their instructions on building the client on my system and their contribution guidelines. So I got to work. I forked the repo, installed the dependencies via maven, installed their required IDE plugins and began figuring out how their API worked. After a couple hours of reading other peoples code, talking to other developers in their discord and learning how the inventory tagging plugin from above works I found the methods I needed to call and additions I need to make to add this feature, and this was the final result:

In the configuration menu I also included a spinner for alpha values from 0-255 which controlled the opacity of the colours:

Now that I was done adding the feature I had to push it to my fill-inventory-tags branch which identified the feature I added and I submitted a pull request. Once submitted, Travis began building the client from my repo and I failed all checks. I was surprised at what I did to fail all checks so I checked Travis’ log to find out. It was a checkstyle violation. I forgot a to add a whitespace after an if statement. A single space… So I added a space and committed my changes, Travis compiled it again and boom, all checks passed. Had me worried for a second.

Unfortunately it hasn’t been merged yet (after 5 days) but I’m not discouraged because as they mention in their FAQ on discord:

In the end while it took a lot of reading, reverse engineering (kind of an overkill term) and understanding I was able to add my first ever feature and contribute it to a project that I love. What a great feeling.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

Create your website with WordPress.com
Get started
%d bloggers like this: