Create method to automatically create a hitbox around the buttons text and image. Keep in mind that there are cases where there is text but no image, image but no text, and both image and text. There can only be one image and one text and maximum though.
The point of this is to allow users to click on either the image or text to press the button instead of one or the other. The final implementation should work for both clicks, hovers, and any other interaction event. This should be accomplished by overwritting phaser's automatic hitbox generation inside setInteractive()
Create method to automatically create a hitbox around the buttons text and image. Keep in mind that there are cases where there is text but no image, image but no text, and both image and text. There can only be one image and one text and maximum though.
The point of this is to allow users to click on either the image or text to press the button instead of one or the other. The final implementation should work for both clicks, hovers, and any other interaction event. This should be accomplished by overwritting phaser's automatic hitbox generation inside setInteractive()