]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/gamemodes/gamemode/onslaught/sv_onslaught.qc
Bot AI: properly fix bot's view angles when bot gets teleported or passes through...
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / gamemodes / gamemode / onslaught / sv_onslaught.qc
index b4c4dc68fed96fa6a6c32b7e47ca2cb0b3a7957f..854e37e5eb71e81baa8646ebe6ebba139ca52d56 100644 (file)
@@ -1625,6 +1625,11 @@ bool ons_Teleport(entity player, entity tele_target, float range, bool tele_effe
                                player.angles = '0 1 0' * ( theta * RAD2DEG + 180 );
                                makevectors(player.angles);
                                player.fixangle = true;
+                               if (IS_BOT_CLIENT(player))
+                               {
+                                       player.v_angle = player.angles;
+                                       bot_aim_reset(player);
+                               }
                                player.teleport_antispam = time + autocvar_g_onslaught_teleport_wait;
 
                                if ( tele_effects )