From the very start I was given the resources and help to get going on this project.
I've been dabbling in C++ for only a couple of months now, but the codebase has been so clean and well laid out that it's been relatively painless going in, fixing bugs and adding new features.
What have I done in my first week here?
So far I've fixed a couple of bugs/missing features, nothing too exciting but it got me familiar with the codebase.
The big stuff I've been working on is finishing the Medic profession!
The first thing that needed to be added was to check for proper healing targets (ex: you can't heal non-players)
I came up with a simple method to return the Player as the target there was no valid target. This ended up working well as this will heal the player when they are in not targetting themselves and there's no valid player target to heal.
Next I went about implementing the /healwounds command. This ended up being a little tricky and I had to refactor a lot of the existing Medic code to get it working properly. For example there was an existing method to get a valid medicine for the type of heal we were using... but it only worked for stimpacks, instead of creating a new method, I ended up creating a common method for all medicine to use. It then cycles through the inventory looking for the appropriate medicine and that method then calls the appropriate heal method based on the input. This was half the battle. The other half involved getting the message after /healwound to work properly. IE: /healwound action heals your action . This involved breaking apart the message and re-using some regex code from apathy to get a match if there was a valid /healwound [command]. I ended up breaking this out into a helper function as other commands require similar use. IE: /tendwound [command]. That brings me to my next implementation which was.... /tendwound !
This was relatively straight forward because of the way I had setup /healwound to work, I just had to make sure instead of using a medicine, to setup a way to grab a random value between 1-20 (before skill attributes) and then make the Medic pay for using this instead of using a medpack (ie: 5 wounds to focus/willpower and 2 battlefatigue each time)
Next up is /tenddamage which will be relatively quick/painless, then I can move on to /quickheal and /drag (which won't work properly until we get our proper heightmaps in place).
After that the Doctor profession should be pretty straight forward to implement, by utilizing some of the things I've built in the Medic class.
Woo, more fun to come!




