This is what I came up with off the top of my head. I'm not sure the exact buff names for each thing and whatnot. I think that would work. Personally I'd rather use autoexec to do it. If you figure something out wrong I'd like to know for future reference!
Code
<if spell="*Maneuver">
<command when="aftercast">wait 2;input /ws "dancing chains"</command>
</if>
<if spell="dancing chains">
<if buffactive="overload">
<command when="precast">wait 2;input /ja "cooldown"</command>
<cancelspell/>
</if>
</if>