Bullet and weapon code is done. And some other stuff.

Compared to the rest of the features, it took a bloody while.

I expected to have that part ready before the end of September… but fortunately my perfectionist me kicked in and decided to have a play-test… to see how people would react to the game.

There were two, actually. The first wasn’t really planned by me. But both of them allowed me to gather really interesting bugs during development of those features… and I added some more.

Let me go through some bullet points here of what I actually worked on:

  • I fixed a major bug with file handling, where the .NET Framework got confused with Decimal Separators (basically switching commas by periods, provoking a game crash).
  • There was a “dupe death/score” bug, where two bullets would hit a player. The first would kill him, so theoretically, the second shouldn’t even detect. However, the server wasn’t checking if the player was dead or not, so it was adding another kill to the scoreboard. Now it’s fixed.
  • I nailed down a useful code snippet for showing framerate in-game, instead of having to install Fraps on every test machine. That was a must.
  • The player can now sprint for a certain period before getting tired (and entering a cooldown period).
  • I added a flashlight to each player, allowing them to see in dark spaces. The flashlight is unlimited, but later I may implement a rechargeable one, Half-Life 2-style.
  • Crosshair and hitmark functionality is now implemented as well. Whenever the player hits another, a cross (x) appears for a brief time above the crosshair.
  • I had to implement a sort-of crash log functionality. In the first playtest, some players crashed mid-game and I didn’t really have a way to diagnose those crashes. For the next playtest, I’ll be ready.
  • The spawning algorithm was not really functional. Players would spawn, but on top of each other. That was because of a variable I had wrong in a for loop. Silly me. Thankfully that’s fixed.
  • Weapons are done. There will be five weapons at the beginning, and I might extend it later in the process. Basically an assault rifle, a long-range machine gun, an SMG, a shotgun and a high-caliber rifle.
  • Bullet code is pretty much done, hit-detection is smooth, but I still need to tweak more before jumping into conclusions.
  • Some tweaks and optimizations here and there.

And that’s what’s been done since my last blog post. I will work on the HUD next, and tomorrow I’ll have another playtest to see how it runs with this new code. Let’s hope there aren’t anymore bugs.

2 thoughts on “Bullet and weapon code is done. And some other stuff.

    • Ahah, don’t worry, you’re already included ;-)

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 )

Google+ photo

You are commenting using your Google+ 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