$BurstTime = 0.2; // how long one burst lasts
$firing = false;
function BurstFire() {
if ($firing) {
if (getMountedItem(0) == 13) {
postAction(2048, IDACTION_FIRE1, 1);
schedule("postAction(2048, IDACTION_BREAK1, 1);", $BurstTime);
schedule("BurstFire();", $BurstTime + 0.05);
}
else postAction(2048, IDACTION_FIRE1, 1);
}
}
function FireToggle() {
$firing = !$firing;
if ($firing)
BurstFire();
else postAction(2048, IDACTION_BREAK1, 1);
}
bindCommand(mouse0, button0, make, TO, "FireToggle();");
bindCommand(mouse0, button0, break, TO, "FireToggle();");