I am pretty sure this behaviour was copied from the reinforcement RAT guards, which actually pull out a melee weapon when enemies get within a close proximity. The other humanoid entities however, don't possess a melee weapon and kind of awkwardly run to the player and proceed to rub themselves against the player.
They of course keep using their ranged weapon. It's especially noticable during double cross, but it can occur anywhere.
I am pretty sure this behaviour was copied from the reinforcement RAT guards, which actually pull out a melee weapon when enemies get within a close proximity. The other humanoid entities however, don't possess a melee weapon and kind of awkwardly run to the player and proceed to rub themselves against the player.
They of course keep using their ranged weapon. It's especially noticable during double cross, but it can occur anywhere.