This is caused by the in-game setting under the graphics section the setting is named “Pause Game on focus lost”