MicroTransports improvement and the addon bug
Simplifying MicroTransports.cpp reduced its length by about 150 lines of code. That was rather a lot of extra code for the small job of moving around the edge of the map—and the waypoint method that I’m sticking with is hardly the simplest way. The savings in memory use (it takes less than half as much) and runtime (ditto) are greater—not big enough to make an overall difference, but reducing overhead is always good. Most importantly, the code is much clearer, so the future improvements needed for drop will be easier. The detailed behavior is slightly different, not much. There is still a bug in choosing which direction to go around the map, but I’ll solve it.
In vaguely related news, dropping sometimes triggers Steamhammer’s addon bug. The bug is that when building a terran addon, such as the control tower for a starport, sometimes the addon is ordered but never built, wrecking the build order. BWAPI says that the addon will build, but when the order is issued, it doesn’t. In practice, it happens when the control tower comes up in the queue at about the same time that the starport finishes. My latest theory is that there is a latency period after the starport finishes before the control tower can start, and BWAPI doesn’t recognize it.
The last time I worked on this bug, I struggled a long time and finally gave up. I ended up inserting filler items into the openings to delay addons so that they are unlikely to be ordered early and trigger the bug. Of course that makes play worse, but it was a workaround. The bug came up again because queue reordering cleverly realized, “Hey, this addon can be moved up, let’s build it now!” and triggered the bug in half of games.
For now, I told queue reordering not to pull an addon to the front. 2 hacky workarounds for the same bug are too many. This time I’m determined to get to the bottom of it. So... any hints?
Comments
Stanislaw Halik on :
Check building's or worker's action a few ticks later. It should be what you ordered. Only after the action's verified, proceed any further with build order stuff.
Jay Scott on :
Anon on :
Jay Scott on :
Stanislaw Halik on :
It's interesting how many simple things bots get wrong. They don't find holes in turret defenses, or are unwilling to get through a static base defense repeating the approach indefinitely. It's sad watching all good play get ruined due to the bot getting "stuck" in a bad state.
Also, are you using SparCraft or have you rolled up your own estimator?
Jay Scott on :
Jay Scott on :
Stanislaw Halik on :
a) Plot a path with many nodes, coming to a full stop if necessary to draw a precise path.
b) Give a safety margin.
c) Scout around the cliff.
I can imagine that performing well for most/all common game skills is a herculean task. Priorities...
Jay Scott on :
Jay Scott on :
Jay Scott on :
Joseph Huang on :
Marian on :
For this problem:
custom order: OrderBuildAddon
-> assign to starport
-> reserve gas/minerals
-> order executed each frame and checks itself for completion and failures(basically state machine)
Ankmairdor on :
Jay Scott on :