Hi guys, I'm learning a bit of javascript and I would like to try to create a window to practice some ideas on it
However I can't get my window to show in the game
Here is my code:
Then in the game I have an event that calls this function, I have tested it by adding $gameMessage.add("hi"); in the script and works.
I have tried to look at code examples on the internet, but nevertheless they seem very complex for my current knowledge of js, I would appreciate any help to understand how classes work in rpg maker.
However I can't get my window to show in the game
Here is my code:
function helloWorld()
{
var simpleWindow= new Window_Base(200,200,300,300);
simpleWindow.activate();
simpleWindow.open();
simpleWindow.show();
simpleWindow.drawText("Hello World", 200,200,300,"center");
}
Then in the game I have an event that calls this function, I have tested it by adding $gameMessage.add("hi"); in the script and works.
I have tried to look at code examples on the internet, but nevertheless they seem very complex for my current knowledge of js, I would appreciate any help to understand how classes work in rpg maker.