]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/bot/default/bot.qc
Merge branch 'master' into Mario/weaponorder
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / bot / default / bot.qc
index 5d34484912b868ad775a83d140b439570522021a..40afed17990b7e93c40e41e194b5893054c54911 100644 (file)
@@ -241,6 +241,9 @@ void bot_setnameandstuff(entity this)
        READSKILL(bot_thinkskill, 1, 0.5); // think skill
        READSKILL(bot_aiskill, 2, 0); // "ai" skill
 
+       if (file >= 0 && argv(prio) != "")
+               LOG_INFOF("^1Warning^7: too many parameters for bot %s, please check format of %s", bot_name, autocvar_bot_config_file);
+
        this.bot_config_loaded = true;
 
        // this is really only a default, TeamBalance_JoinBestTeam is called later
@@ -427,9 +430,9 @@ void bot_clientconnect(entity this)
                bot_setclientfields(this);
        }
 
-       if (Team_IsValidIndex(this.bot_forced_team))
+       if (teamplay && Team_IsValidIndex(this.bot_forced_team))
        {
-               this.team = Team_IndexToTeam(this.bot_forced_team);
+               SetPlayerTeam(this, this.bot_forced_team, TEAM_CHANGE_MANUAL);
        }
        else
        {
@@ -577,6 +580,7 @@ void bot_calculate_stepheightvec()
        stepheightvec = autocvar_sv_stepheight * '0 0 1';
        jumpheight_vec = (autocvar_sv_jumpvelocity ** 2) / (2 * autocvar_sv_gravity) * '0 0 1';
        jumpstepheightvec = stepheightvec + jumpheight_vec * 0.85; // reduce it a bit to make the jumps easy
+       jumpheight_time = autocvar_sv_jumpvelocity / autocvar_sv_gravity;
 }
 
 bool bot_fixcount()
@@ -753,7 +757,7 @@ void bot_serverframe()
                if(botframe_cachedwaypointlinks)
                {
                        if(!botframe_loadedforcedlinks)
-                               waypoint_load_links_hardwired();
+                               waypoint_load_hardwiredlinks();
                }
                else
                {