making pop-ups

Hello everyone, I'm just now starting into Java Script and I was wanting to make A pop up plugin, where I can call A pop up with some text, the call I would like to have something like Popup("say this",s) s would be the seconds it shows. I know some other programming languages i just don't know where to start with java script and rmmv.

I've tried looking though the the core code for the pieces that I need like the window base, I'm not quite sure how to put it together. I have been watching a Video and this is what I have

Window_Sample.prototype.windowHeight = function(){ return this.fittingheight(1);0 }; Window_Sample.prototype.refresh = function(){ var x = this.textPadding(); var width = this.contents.width - this.textPadding() * 2; this.contents.clear(); this.drawIcon(2,0,0); }; Window_sample.prototype.open = function() { this.refresh(); Window_Base.prototype.open.call(this); }; function Sample_scene(){ this.initialize.apply(this, arguments); }; Sample_scene.prototype = object.create(scene_MenuBase.prototype); Sample_Scene.prototype.constructor = Sample_Scene; Sample_Scene.prototype.initialize = function(){ Scene_MenuBase.prototype.create.call(this); }; Sample_Scene.prototype.create = function(){ Scene_MenuBase.prototype.create.call(this) this._sampleWindow = new Window_Sample this.sampleWindow.x = Graphics.width / 2 - 100; this.sampleWindow.y = Graphics.height / 2 - 100; this.addWindow(this._sampleWindow); }; Sample_Scene.prototype.start = function(){ Scene_MenuBase.prototype.start.call(this); };I have just been trying to make a basic window display on the screen, I've made A title skip plugin but that sort of helped my understanding of finding the pieces of code in the core rmmv code. 
First of all you have some capitalization consistency issues (i.e. Sample_Scene vs Sample_scene), which will not make the code functional. Ensure all capitalization is accurate or things will not function as intended.

I won't be writing your entire required code to create a popup window, but your actual window code is not functional in the current state because it isn't a valid class and has no reference to the actual Window class.

Here's a basic example of how to setup a sample window and immediately refresh it to draw contents:

function Window_Sample() { this.initialize.apply(this, arguments);}Window_Sample.prototype = Object.create(Window_Base.prototype);Window_Sample.prototype.constructor = Window_Sample;Window_Sample.prototype.initialize = function(x, y, width, height) { Window_Base.prototype.initialize.call(this, x, y, width, height); this.refresh();};In your create() function for Sample_Scene you have some typos that will not let your script work as intended (and will actually cause an error). You have:

this._sampleWindow = new Window_Sample this.sampleWindow.x = Graphics.width / 2 - 100; this.sampleWindow.y = Graphics.height / 2 - 100; this.addWindow(this._sampleWindow);But it should be:

this._sampleWindow = new Window_Sample(); this._sampleWindow.x = Graphics.boxWidth / 2 - 100; this._sampleWindow.y = Graphics.boxHeight / 2 - 100; this.addWindow(this._sampleWindow);Please note that my example window code does not work with the above initialization of the Window_Sample class as it requires arguments passed into it.

Hopefully this explains naming conventions and how to set up classes that inherits other classes.
Thank you, this was probably the push I needed. I was watching the video and typing with it, I'm new to Java script so I wasn't aware of my punctuation errors. That actually explains alot. 

Here is my title skip code, it wasn't that hard actually, just a little bit of searching. Youtube can be helpful when it wants but with resources being what they are I look for something that hits close to home and do it.  

Code:
/*: * @plugindesc Skip Title Screen * @author Mark *@help This Plugin will make testing alot faster. * *@param  * */Scene_Boot.prototype.start = function() {    Scene_Base.prototype.start.call(this);    SoundManager.preloadImportantSounds();    if (DataManager.isBattleTest()) {        DataManager.setupBattleTest();        SceneManager.goto(Scene_Battle);    } else if (DataManager.isEventTest()) {        DataManager.setupEventTest();        SceneManager.goto(Scene_Map);    } else {        this.checkPlayerLocation();        DataManager.setupNewGame();        SceneManager.goto(Scene_Title);        Window_TitleCommand.initCommandPosition();    	SceneManager.goto(Scene_Map);    }    this.updateDocumentTitle();};

Original thread: https://forums.rpgmakerweb.com/threads/making-pop-ups.52368/