Place it in the middle of a gag, after the setup and before the fallout, so the stretch carries the joke forward. Open with It Was At This Moment He Knew to frame the trouble, then let the stretch build, and close with a fail sound once the plan collapses.