archive by month
Skip to content

Steamhammer occasionally takes a barren base

Steamhammer occasionally likes to expand to mined-out bases late in the game. I have made a whole series of changes over different versions to fix it: I had it score bases by available resources, I had it avoid bases altogether which don’t have enough minerals to be worth it, then I extended it to avoid bases where the geyser is mined out. And still there was one recent game where Steamhammer took an empty base.

Finally it dawned on me that Starcraft is a game of imperfect information. If you choose your next base when you can’t see it, then of course you’ll sometimes choose the wrong base. Oh... I think I should have learned that by now. And yet just today I was fixing visibility mistakes in the base code, where it called getTilePosition() instead of getInitialTilePosition(). Somehow it’s easy to forget.

Does that account for all the cases? I’m not sure. It’s a somewhat rare bug, but I have a feeling that the most common empty base to take is the enemy’s natural after destroying it, when it should be visible. Maybe there’s yet another bug, which would be depressing.

How many more bugs are there because I am sometimes blind to the basic workings of BWAPI? I bet there are more than a few. Software is hard.

Trackbacks

No Trackbacks

Comments

Joseph Huang on :

I don't think SH tracks available resources, it can only know how much resources there are if they are currently visible.

Jay Scott on :

Just so. Resource tracking is feature to be added to the new base code, and has been. Yet I never made the connection.

Add Comment

E-Mail addresses will not be displayed and will only be used for E-Mail notifications.

To prevent automated Bots from commentspamming, please enter the string you see in the image below in the appropriate input box. Your comment will only be submitted if the strings match. Please ensure that your browser supports and accepts cookies, or your comment cannot be verified correctly.
CAPTCHA

Form options

Submitted comments will be subject to moderation before being displayed.