The feature you ask for will be available in RepRapFirmware 3 when I finish implementing conditional GCode.