Place a unit (any unit as long as he has an automatic weapon) on the map.
Give him both accessories:
player linkItem "acc_flashlight";
player addItem "acc_pointer_IR";
Select "full auto" or "burst"
Paste this in your debug monitor:
player action ["GunLightOn",player];
Note that the light is switched on and you now are in single-shot mode.
Change to IR laser and repeat with
player action ["IRLaserOn",player];