Dentosal / python-sc2

A StarCraft II bot api client library for Python 3
MIT License
586 stars 182 forks source link

map_ramps contain vision blockers and dont contain blocked ramps #248

Open tweakimp opened 5 years ago

tweakimp commented 5 years ago

Currently, gameinfo.map_ramps contains vision blockers because the current ramp point condition self.placement_grid[(x, y)] == 0 and self.pathing_grid[(x, y)] == 0 is also true for them.

I think it is easier to filter them out by checking if there are different heights in these wrong Ramp objects, but maybe we can also change the ramp point condition in _find_ramps,

On the other hand, ramps that are blocked by destructable rocks are not in map_ramps. I dont know how to find them. We have the position of each destructable, but that is only one position, not the whole ramp. Can we maybe get a footprint of it by its type_id?

tweakimp commented 5 years ago

Fixed in https://github.com/Dentosal/python-sc2/pull/275

tweakimp commented 5 years ago

Only partly fixed...

ramps blocked by rocks are still not counted as ramps