This works in the same way as the FCPX "Image Mask" except it works with animated mattes, not just still image mattes.
It has been setup to work with all SD, HD, 4K & 5K resolutions at all available frame rates from 23.98 to 60fps in FCPX.
It also has a PDF file inside the folder. This folder, as downloaded from the link below, should be put inside a "Custom" named folder in your "Effects" folder inside your "Motion Templates" folder in your "Movies" directory.
Thank you for creating this. I thought no one had thought to create this seeing how FCPX deals with luma and alpha mattes. But you figured it out and for that I commend you. Will have a tutorial out in the near future.