@ncmako - Here is a revised version of the turret script which now manages the hud messages properly, replaces the turret if player killed whilst using it and stops the player from being able to weapon switch with the mouse. I also changed the turret weapon slot to 9 as its a special weapon and didn't want it to replace any primary weapons the player has picked up already.
If you press the numbers 1-8 on the keyboard it will bring up the weapon in that slot which is still a problem but a step in the right direction.
;Artificial Intelligence Script
desc = plrwithin display mini gun hud
;PLAYER HAS A WEAPON
;End of Script