Node fixed, can disable sv_lanonly

This commit is contained in:
INeedBots 2020-11-18 01:28:16 -06:00
parent 1c5090fbc1
commit 0b039fc397
2 changed files with 24 additions and 2 deletions

View File

@ -1707,6 +1707,21 @@ AStarSearch(start, goal, team, greedy_path)
if(isDefined(_goalwp))
goalwp = _goalwp;
goalwp = goalwp.index;
/*storeKey = "astarcache " + startwp + " " + goalwp;
if (StoreHas(storeKey))
{
path = [];
pathArrStr = tokenizeLine(StoreGet(storeKey), ",");
pathArrSize = pathArrStr.size;
for (i = 0; i < pathArrSize; i++)
{
path[path.size] = int(pathArrStr[i]);
}
return path;
}*/
goalorg = level.waypoints[goalWp].origin;
@ -1734,6 +1749,7 @@ AStarSearch(start, goal, team, greedy_path)
if(bestNode.index == goalwp)
{
path = [];
//storeStr = "";
while(isDefined(bestNode))
{
@ -1742,10 +1758,16 @@ AStarSearch(start, goal, team, greedy_path)
//construct path
path[path.size] = bestNode.index;
//storeStr += bestNode.index;
bestNode = bestNode.parent;
/*if (isDefined(bestNode))
storeStr += ",";*/
}
//StoreSet(storeKey, storeStr);
return path;
}

View File

@ -1 +1 @@
start "" "%~dp0iw4x.exe" -dedicated +set sv_lanonly "1" +set net_port "28960" +set fs_game "" +exec server.cfg +map_rotate
start "" "%~dp0iw4x.exe" -dedicated +set sv_lanonly "0" +set net_port "28960" +set fs_game "" +exec server.cfg +map_rotate