]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Merge branch 'master' into terencehill/bot_waypoints
authorterencehill <piuntn@gmail.com>
Tue, 29 Aug 2017 15:39:05 +0000 (17:39 +0200)
committerterencehill <piuntn@gmail.com>
Tue, 29 Aug 2017 15:39:05 +0000 (17:39 +0200)
# Conflicts:
# qcsrc/server/command/sv_cmd.qc
# qcsrc/server/impulse.qc

1  2 
qcsrc/common/triggers/teleporters.qc
qcsrc/server/bot/default/bot.qc
qcsrc/server/bot/default/waypoints.qc
qcsrc/server/command/sv_cmd.qc
qcsrc/server/sv_main.qc

index 13a0c41d3fdbb83cda4363935a1e341f8f8b5dd5,8e9936b2ea2980586e44844ccb66b27f92801670..2ba6e7e3c704f8b283a28dd0e0bfaccee7abc767
@@@ -235,15 -235,9 +235,15 @@@ void teleport_findtarget(entity this
                ++n;
  #ifdef SVQC
                if(e.move_movetype == MOVETYPE_NONE)
 -                      waypoint_spawnforteleporter(this, e.origin, 0);
 +              {
 +                      entity tracetest_ent = spawn();
 +                      setsize(tracetest_ent, PL_MIN_CONST, PL_MAX_CONST);
 +                      tracetest_ent.dphitcontentsmask = DPCONTENTS_SOLID | DPCONTENTS_BODY | DPCONTENTS_PLAYERCLIP | DPCONTENTS_BOTCLIP;
 +                      waypoint_spawnforteleporter(this, e.origin, 0, tracetest_ent);
 +                      delete(tracetest_ent);
 +              }
                if(e.classname != "info_teleport_destination")
-                       LOG_INFO("^3MAPPER ERROR: teleporter does target an invalid teleport destination entity. Angles will not work.\n");
+                       LOG_INFO("^3MAPPER ERROR: teleporter does target an invalid teleport destination entity. Angles will not work.");
  #endif
        }
  
index 878f076a90ffe280bbb487aee1ace3929efe842e,f8ddd0c637576d81efb058e330c11922d9438a56..f599124db7bbb091e73b94bcbebc7cdfc4a0dbbc
@@@ -684,21 -694,11 +693,24 @@@ void bot_serverframe(
                return;
  
        if (time < 2)
+       {
+               currentbots = -1;
                return;
+       }
  
 +      if(autocvar_skill != skill)
 +      {
 +              float wpcost_update = false;
 +              if(skill >= autocvar_bot_ai_bunnyhop_skilloffset && autocvar_skill < autocvar_bot_ai_bunnyhop_skilloffset)
 +                      wpcost_update = true;
 +              if(skill < autocvar_bot_ai_bunnyhop_skilloffset && autocvar_skill >= autocvar_bot_ai_bunnyhop_skilloffset)
 +                      wpcost_update = true;
 +
 +              skill = autocvar_skill;
 +              if (wpcost_update)
 +                      waypoint_updatecost_foralllinks();
 +      }
 +
        bot_calculate_stepheightvec();
        bot_navigation_movemode = ((autocvar_bot_navigation_ignoreplayers) ? MOVE_NOMONSTERS : MOVE_NORMAL);
  
Simple merge
index 241a48e5c4569b87d62e32cf04761253ab9d52b7,2bb0f1365c3b71aa353be44d6bc7522438344293..43ce29160bbcc755b2ece904dcbe41d2d1fe2299
@@@ -1566,13 -1568,11 +1568,13 @@@ void GameCommand_trace(float request, f
  
                                case "walk":
                                {
 -                                      if (argc == 4)
 +                                      if (argc == 4 || argc == 5)
                                        {
                                                e = nextent(NULL);
 -                                              if (tracewalk(e, stov(argv(2)), e.mins, e.maxs, stov(argv(3)), MOVE_NORMAL)) LOG_INFO("can walk");
 -                                              else LOG_INFO("cannot walk");
 +                                              if (tracewalk(e, stov(argv(2)), e.mins, e.maxs, stov(argv(3)), stof(argv(4)), MOVE_NORMAL))
-                                                       LOG_INFO("can walk\n");
++                                                      LOG_INFO("can walk");
 +                                              else
-                                                       LOG_INFO("cannot walk\n");
++                                                      LOG_INFO("cannot walk");
                                                return;
                                        }
                                }
                }
  
                default:
-                       LOG_INFO("Incorrect parameters for ^2trace^7\n");
+                       LOG_INFO("Incorrect parameters for ^2trace^7");
                case CMD_REQUEST_USAGE:
                {
-                       LOG_INFO("\nUsage:^3 sv_cmd trace command [startpos endpos] [endpos_height]\n");
-                       LOG_INFO("  Where startpos and endpos are parameters for 'walk' and 'showline' commands,\n");
-                       LOG_INFO("  'endpos_height' is an optional parameter for 'walk' command,\n");
-                       LOG_INFO("  Full list of commands here: \"debug, debug2, walk, showline.\"\n");
-                       LOG_INFO("See also: ^2bbox, gettaginfo^7\n");
 -                      LOG_INFO("Usage:^3 sv_cmd trace command (startpos endpos)");
++                      LOG_INFO("Usage:^3 sv_cmd trace command [startpos endpos] [endpos_height]");
++                      LOG_INFO("  Where startpos and endpos are parameters for 'walk' and 'showline' commands,");
++                      LOG_INFO("  'endpos_height' is an optional parameter for 'walk' command,");
+                       LOG_INFO("  Full list of commands here: \"debug, debug2, walk, showline.\"");
+                       LOG_INFO("See also: ^2bbox, gettaginfo^7");
                        return;
                }
        }
Simple merge