Message and Choices not showing up for JS plugin

So this part of my code isn't showing up when I call the scene.  Developer console not displaying any errors since it's not crashing, so I think I may be missing a line or two since this is my first time using the $ RMMV Script commands.


CardGame_Scene.prototype.playMessage = function() {

$gameMessage.setFaceImage('Actor1',0)
$gameMessage.setBackground(1)
$gameMessage.setPositionType(1)
$gameMessage.add('Wanna play?')
choices = [];
params = [];
$gameMessage.setChoices(["Yes", "No"], 0, -1)
$gameMessage.setChoiceCallback(function (choice) {
if (choice == 1) {
SoundManager.playCancel();
SceneManager.goto(Scene_Map);
};
if (choice == 0) {
$gameMessage.add("You currently have \G\$")
var bet;
$gameMessage.setNumberInput(bet, 5);
$gameMessage.setChoices(["I got the cash","Nevermind",0,-1]);
$gameMessage.setChoiceCallback(function (choice) {
if (choice == 1) {
SoundManager.playCancel();
SceneManager.goto(Scene_Map);
};
if (choice == 0) {
$gameParty.gainGold(-bet);
};
});
}; /
});
};


Some lines are deliberately missing semi-colons as per the format of the RMMV script calls list. When I tried having each line end with a semicolon, it doesn't change the effect - the scene pops up fine, but the playMessage doesn't display. 

I started JS just a couple weeks ago, and I'm new to coding in general so any help or tips will be appreciated. 
You are using $gameMessage in a scene that doesn't implement the message system, is my bet.


Scene_Map and Scene_Battle by default are the only ones that implements it.


Here's the default code snippet:


Scene_Map.prototype.createMessageWindow = function() {
this._messageWindow = new Window_Message();
this.addWindow(this._messageWindow);
this._messageWindow.subWindows().forEach(function(window) {
this.addWindow(window);
}, this);
};


To clarify, if there's no Window_Message, $gameMessage calls only sets a bunch of values to that object, and displays nothing.

Original thread: https://forums.rpgmakerweb.com/threads/message-and-choices-not-showing-up-for-js-plugin.55239/