Add method to MovieClip

Hello, I’m trying to create a package so that when I import the package it will add a center_to_stage method to the movieclip. So i want to call it like this:

myClip.center_to_stage();

//here is the code (obviously it doesn’t work):

package bmilesp.display {
    
    import flash.display.MovieClip;
    import flash.display.Stage;
    
    public class MovieClip extends MovieClip(){
        
        public function center_to_stage():void{
            
            trace(this.name);
            
        }
    } 
}

any suggestions on how to do this right? thank you!