ps: replaced the prim with ?(tx_prim == "FDF_HK69"): tx_prim = "HK69A1"
I dont think you understand what i meant by restating tx_prim
Basically weapons like the M16GL and the AK74GL have more than one muzzle mode
For these specific type of weapons, you have to state which muzzle mode you need to select when selecting the weapon as primary otherwise as a player, you have to press spacebar to get a weapon mode, be it gl or auto, semi auto etc
so if the FDF_HK69 was an assault rifle/grenade launcher you would probably have to type
?(tx_prim == "FDF_HK69"): tx_prim = "HK69muzzle"
what you are actually stating is
if my primary weapon is a fdf_hk69 then i need to select it in "Muzzle mode" not grenade launcher mode
If its a standard, 1 ammo type weapon, then you dont need to add it to the
?(tx_Prim == "XXXXX"):
as there is only 1 muzzle to select and that will be done automatically
I Have changed the killed event handler lines (I cant remember how to specifically remove a certain eventhandler, but as it would appear that you havent used any yourself, the script simply removes all of them on death
INIT.SQStx_mags = magazines player
tx_weps = weapons player
tx_prim = primaryweapon player
Player addEventHandler ["killed", {_this exec "unitkilled.sqs"}]
UNITKILLED.SQSPlayer removeallEventhandlers "Killed"
@ alive Player
removeallweapons Player
{Player addMagazine _x} forEach tx_mags
{_unit addWeapon _x} forEach tx_weps
;;;;;;;;;; BIS Standard
?(tx_prim == "M16GrenadeLauncher"): tx_prim = "M16Muzzle"
?(tx_prim == "Ak74GrenadeLauncher"): tx_prim = "AK74Muzzle"
?(tx_prim == "Ak47GrenadeLauncher"): tx_prim = "AK47Muzzle"
Player selectWeapon tx_prim
Player addEventHandler ["killed", {_this exec "unitkilled.sqs"}]