Saturday, January 26, 2008

Test server 25-Jan release

The 25-Jan-2008 build of the Test server has a bunch of new combat log messages available to help track accuracy. You can see the patch notes on the official forums. What this means to HeroStats is that it's now much easier to track accuracy of a power, and it's even possible to see the accuracy of an enemy's powers!

The latest unstable build (download it from the unstable web site) takes these new combat log messages into account. You'll see a bunch of new statistics related to accuracy if you're running the unstable build on Test. Here's a brief rundown of what's new:
  • Both player and enemy accuracy is tracked. Each section discussed below comes in two flavors, one for player stats and one for enemy stats. For players, everything is tracked by power. For enemies, it's tracked by both enemy type and power (since a Behemoth's version of Fire Sword might be different than the Fire Thorn Caster version of Fire Sword).
  • [Player/Enemy] Accuracy: This section measures the actual accuracy for each power over the time you've been collecting statistics. It's calculated from actual hits / (actual hits + actual misses).
  • [Player/Enemy] Hits and Misses: A detailed breakdown of the number of hits and misses per power.
    • Hits and Misses are simply counted from the new log messages.
    • Hits (calculated) is generated by looking for messages where the roll is less than or equal to the percent chance to-hit. That's a debugging tool, mainly - in theory Hits should always equal Hits (calculated) - if it doesn't then something's not right.
    • Number of Rolls is the count of times you had to make a to-hit roll. You might think this should always be equal to the number of times you attacked, but it's not always the case - sometimes a power is auto-hit, and sometimes the streakbreaker gets involved.
    • Streakbreaker Count is the number of times the streakbreaker was used to force a hit. I'm not going to try to describe the streakbreaker here, Arcanaville's Guide to Defense does it better than I would.
  • [Player/Enemy] To-Hit Chance: The to-hit chance percentage from the new combat log messages.
    • Average is exactly what you'd expect, the average of the percentages from all the hits and misses for the power. Note that auto-hit and streakbreaker "hits" aren't counted.
    • Total isn't all that useful, it just adds up all the to-hit numbers. It's used for calculating the average.
  • [Player/Enemy] To-Hit Rolls: The to-hit rolls from the new combat log messages. This is the same as the to-hit chance above except it's the roll numbers.
The old accuracy and hit/miss stats are still in HeroStats for now. Once these new combat log messages are stabilized I'll probably remove that, but for now it's interesting to see how the old and new ways differ. From the little testing I've done so far, they're pretty much the same, which is a good thing.

All this information is accurate as of the 25-Jan-2008 Test build and the 3.9.9.8 version of HeroStats. New Test builds and new HeroStats versions could be a bit different, keep an eye on the change logs for each.

Friday, January 11, 2008

HeroStats, Real Numbers, and City Vault

With the new year, NCSoft has announced several upcoming features for City of Heroes/Villains in their 2008 State of the Game article. There's a lot of good information there which I encourage everyone interested in CoX to read. Here, I'd like to address a couple of things of interest to HeroStats users.

The Real Numbers

As a general quality of life improvement we will be adding new functionality in a coming version of the game to display the “real” numbers behind your characters and their powers. This includes a user configurable display of important characteristics such as movement rate, regeneration rate, resistances and many more! Additionally, you will be able to see how those statistics are affected in real time by buffs and/or debuffs affecting your character.

The article mentions the ability to display the actual values for the various statistics that your character has - regeneration, resistance, movement, etc. Let me first say that I think this is long overdue, and a welcome change. I remember this request coming up way back in City of Heroes beta, and it's been a regular discussion topic ever since. It's great to hear that it's coming.

One of the core functions of HeroStats has always been to track the actual values during a play session for the accuracy of your powers, damage dealt, damage received, etc. Note that the article didn't mention any of these sorts of statistics. It's possible they may be included, and that would be wonderful, but I have my doubts. As long as this sort of information is not available through the game client, HeroStats will continue to provide it.

What was mentioned in the article is the type of information you see in a build planner. How much resistance to smash/lethal do I have? What's my total regeneration? Those sorts of statistics have never been tracked by HeroStats (because they don't show up in the combat log). It's great to see that this information will be available without having to put all my information into an external build planner tool. (Side note - build planners will still be useful, though. There was no mention in the article of any way to do a "what if" scenario, and that's where the build planners are most useful.)

There's one possible area of overlap - recharge timers. If the UI is going to be able to display how much time is left before a power recharges, the recharge timer function of HeroStats may become obsolete. This wouldn't break my heart - recharge timers are less than completely accurate, as I've described before. If the developers want to change the game UI to do a better job, more power to 'em.

Here again, however, I have my doubts. There was much furor on the forums about the UI change to have buff timers blink 10 seconds before expiration, and how it would make HeroStats buff timers obsolete. Hasn't happened - plenty of people still use HeroStats for tracking buffs, because 10 seconds just isn't enough warning much of the time. We'll have to see exactly how the UI changes are implemented before making any assumptions about what HeroStats functions will become obsolete.

City Vault

We gave a sneak peak of the new “City Vault” feature at the recent San Jose Meet ‘n Greet. The City Vault is coming soon to the City of Heroes website and will showcase the millions of interesting Heroes and Villains found in Paragon City and the Rogue Isles. It will allow you to search for characters by a number of different criteria, and then view those characters, including images of different costumes, powers, badges, friends, stats by zone and other fun information! As we have previously announced, you can manage what information will be displayed through the City Vault for your characters via several in game options.

Again, let me first say that I'm very happy to see this. The ability to see in-game info outside of the game has been a much-requested feature for a long time. It's great to see it becoming reality.

None of the functions mentioned in the article will impact HeroStats directly. The core function of HeroStats, tracking statistics within a play session, is in no way impacted by the ability to view character information on the web.

HeroStats does, however, have some secondary functions that could be impacted by the City Vault. Several community websites (see our affiliates list at http://herostats.org) use HeroStats to gather information about characters. Much of this information may now be viewable through the City Vault.

We'll have to wait for the actual City Vault to be available to know exactly how it will impact these community websites. At the moment, I'm willing to say that it's highly unlikely that the City Vault feed will be real-time (for performance reasons) and therefore a site like City Game Tracker, which allows you to see who is online at a particular time, will still be useful. Badge tracking sites typically provide quite a bit more functionality than simply listing badges - showing uncollected badges, for instance, or listing the top badge collectors on a server - so those will still be useful as well.

As for HeroStats, the main impact will be in the data we're sending to the community websites. Some, like City Game Tracker, probably won't change at all. Others, like the badge sites, might start getting their information from the City Vault and not need HeroStats at all. It's difficult to say until we see the City Vault in action, and have some idea how easy or difficult it will be to use that information.

Friday, January 4, 2008

Why does it take so long to load HeroStats?

I've seen a few people ask this question in the past. I freely admit that HeroStats takes a good long time to start up initially. And to make matters worse, while it's starting, it eats up most of your CPU so other programs are impacted. So why does this happen?

The answer, as in most programming, comes down to a trade-off. HeroStats makes heavy use of regular expressions (also known as regexs) to parse the text of the combat log into the stats that everyone wants. Regexs are a great way to recognize text messages and get information out of them, but they require a good deal of setup time if you want them to run quickly. This is known as compiling the regexs and it takes a lot of your computer's CPU time.

And we certainly want them to run quickly. HeroStats scans the CoX client chat tabs twice every second to look for new messages. Every time a new message is found, we have to run through the regexs to figure out what that message means. The code is pretty smart about checking the most common regexs first, but it can still take quite a while to go through them all, especially if your message happens to be one that isn't used very often.

So we want the regexs to run quickly, but in order to do that we need to spend the time to set them up first. And this is why your HeroStats takes a while to start up. It's loading up all those regexs so that while you're actually playing the game, your statistics/timers/etc. are being pulled quickly from those log messages.