MV Uncaught TypeError: displayObject._mask.containsPoint is not a function

So I've managed to get the drill effect to work on my Cleaning Plugin. However, when I apply a simple mask to the layer hidden below the topmost rock layer, it gives me the above error. Here is how I did the code that might have caused the error (plus the bitmap I am using):

JavaScript:
Spriteset_Cleaning.prototype.punctureHoles = function() {
    this._holeSprite = new Sprite();
    this._holeSprite.bitmap = this.holeBitmap();
    this._holeSprite.bitmap.blt(this._holeSprite.bitmap, 0, 0, 16, 16, 0, 0);   // blit onto fresh canvas
    this._holeSprite.move(TouchInput._x, TouchInput._y);
    this._rockL1.addChild(this._holeSprite);
    this._rockL2.mask = this._holeSprite.children;
};

Spoiler: DrillMask
Drill.png
Looks like you've tried to assign an array, children, to a property that expects a single image, mask. I'm not really familiar with CSS or PIXI masking (I know there are/were some users active here knowledgable about that), but I think for multiple masks you'd want to render them to a single image and assign that as the mask? Or maybe you can just assign the parent sprite, not sure how that works.

In case it helps, I did a quick search and found this thread:
Couple more notes:
  • It seems like your code will re-paint the top-left 16x16 px of holeBitmap onto itself with no offset. I'm not sure that's what you intended? 😅

  • The source image for blitting and the image mask should be loaded into separate identifiers to avoid affecting the cached image, e.g. this._holeSource and this._cleaningMask. That said, the thread I linked seems to suggest that blitting is unnecessary if you use PIXI masks.
So how would you go about storing the coordinates of the drill bitmap that has been previously placed? I'm assuming it will involve using the aforementioned this._holeSource and this._cleaningMask examples. So far it seems to work the way I desire it to: Cleaning Drill Effect Video Take 2
Oh, looks good! If it works then I guess it's OK, don't mind me~ 😊
Just one more question: How would I go about tracking the number of Drill Bitmaps created?

Original thread: https://forums.rpgmakerweb.com/threads/uncaught-typeerror-displayobject-_mask-containspoint-is-not-a-function.133695/