graph: always use lowercase map name when downloading graph
package: use default graph endpoint instead of cdn
This commit is contained in:
parent
18456c2a28
commit
8f688b1bc7
3 changed files with 6 additions and 3 deletions
|
|
@ -95,7 +95,7 @@ class BotRelease(object):
|
||||||
self.project = 'yapb'
|
self.project = 'yapb'
|
||||||
self.version = sys.argv[1]
|
self.version = sys.argv[1]
|
||||||
self.artifacts = 'artifacts'
|
self.artifacts = 'artifacts'
|
||||||
self.graphs = 'yapb-gcdn.akamaized.net'
|
self.graphs = 'yapb.jeefo.net'
|
||||||
self.win32exe = 'https://github.com/yapb/setup/releases/latest/download/botsetup.exe'
|
self.win32exe = 'https://github.com/yapb/setup/releases/latest/download/botsetup.exe'
|
||||||
|
|
||||||
meson_src_root_env = 'MESON_SOURCE_ROOT'
|
meson_src_root_env = 'MESON_SOURCE_ROOT'
|
||||||
|
|
|
||||||
|
|
@ -1611,7 +1611,7 @@ bool BotGraph::loadGraphData () {
|
||||||
int mapSize = getBspSize ();
|
int mapSize = getBspSize ();
|
||||||
|
|
||||||
if (mapSize != exten.mapSize) {
|
if (mapSize != exten.mapSize) {
|
||||||
msg ("Warning: Graph data is probably not for this map. Please check bots behaviour.");
|
msg ("Warning: Graph data is probably not for this map. Please check bots behavior.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
cv_debug_goal.set (kInvalidNodeIndex);
|
cv_debug_goal.set (kInvalidNodeIndex);
|
||||||
|
|
|
||||||
|
|
@ -43,10 +43,13 @@ template <typename U> bool BotStorage::load (SmallArray <U> &data, ExtenHeader *
|
||||||
if (!graph.canDownload ()) {
|
if (!graph.canDownload ()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
String lowercaseMapName = game.getMapName ();
|
||||||
|
lowercaseMapName = lowercaseMapName.lowercase ();
|
||||||
|
|
||||||
auto downloadAddress = cv_graph_url.str ();
|
auto downloadAddress = cv_graph_url.str ();
|
||||||
|
|
||||||
auto toDownload = buildPath (storageToBotFile (type.option), false);
|
auto toDownload = buildPath (storageToBotFile (type.option), false);
|
||||||
auto fromDownload = strings.format ("http://%s/graph/%s.graph", downloadAddress, game.getMapName ());
|
auto fromDownload = strings.format ("http://%s/graph/%s.graph", downloadAddress, lowercaseMapName);
|
||||||
|
|
||||||
// try to download
|
// try to download
|
||||||
if (http.downloadFile (fromDownload, toDownload)) {
|
if (http.downloadFile (fromDownload, toDownload)) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue