in asking your question here more specifically, you might find some of the design/planning on your own. without specifics on what the two sounds consist of(sampling, synthesis, etc.?) and what ‘clicking on buttons’ actually does(i.e. standard buttons which ‘play’ and ‘stop’? or something more?), one could just guess something simple like this:
-- Pasted Max Patch, click to expand. --
Copy all of the following text. Then, in Max, select New From Clipboard.