Draw Text on screen

I'd like to know how to display a text/variable on the screen. I made a time plugin and want to display the time on the screen but don't know how to get the text to be drawn on the screen.
I would start by thinking about what other things draw text on the screen.

I can think of the map name will appear, this is where I would start.

You will have to make it apart of the Scene_Map so it can display.
To save yourself the trouble of all that backtracking, you'll need to create a sprite, in this case it seems Sprite_Base will do fine. Then, with that sprite you need to attach a new Bitmap to it, which is the part you can actually draw on. Once this is done, you need to, within the scene itself, call 

this.addChild(mySprite)where mySprite is the variable you used when you created the sprite. Now that we got all the technicalities out of the way, feel free to draw on the sprite like so:

mySprite.bitmap.drawText("text", x, y, maxWidth, lineHeight, "alignment")For the specifics of the drawText function, check the manual's documentation for Bitmap, it'll be there.

Original thread: https://forums.rpgmakerweb.com/threads/draw-text-on-screen.48087/