error when entering battles - AltMenuScreen2MZ "Uncaught TypeError: this.isSceneNeedsAdjustGauge is not a function"

Hi folks, first time posting in a long time so unclear if this should be a new thread or linked to the one mentioned below.

I recently added the AltMenuScreen2MZ plugin into my RPG Maker MZ project (Steam version with DLC plugins) and it works fine for the most part, however when entering battles (Testing in Database OR in game) it prompts the following error "Uncaught TypeError: this.isSceneNeedsAdjustGauge is not a function"

Troubleshooting so far:
Initially it displayed "Uncaught TypeError: this.isSceneNeedsAdjutGauge is not a function" so I disabled all my plugins and re-enabled them one at a time and discovered that it was the AltMenuScreen2MZ plugin causing the error, even without any other plugins enabled. After that I tested using the plugin in different areas of the list (top, bottom, middle etc) and nothing was working I did some searching for a post about the same issue I found one that suggested it was the typo of "NeedsAdjutGauge" that may have been the issue, however even after updating every instance of the "typo" within the AltMenuScreen2MZ plugin the error persists with the new wording - The original post I got this advice from is from Dec 30, 2022 and never actually included a conclusion as the OP never responded back to it or confirmed what plugins they were using so I didn't think this qualified to be posted in that post - I'm reaching a wall in my troubleshooting.

I've included the Error, Console log, Plugin Settings and list of current Plugins below as evidence/reference - Any advice on what is happend and how to resolve is greatly appreciated!

Additional Info: Other than the above mentioned edit to the AltMenuScreen2MZ plugin's "NeedAdjutGauge" wording I have not edited any Plugins or anything else outside of the Plugin Settings window

Error:
1690453134633.png


Console Log:
1690453100258.png



Currently installed plugins:
1690453474189.png


Plugin Settings:
1690454025725.png
Type error (which has nothing to do with typo) is one of the common errors that can happen when you try to continue an incompatible savegame.

and each change in the plugin manager (adding or removing plugins) has a high chance of making old savefiles incompatible.

with the tests above, have you always selected "new game" at the title screen, or did the error happen only after loadign savegames?
Hey Andar, the issue happens regardless of New Game or Continue Game (Loading a save) - and also occurs in the Troops section of the database when using "Battle Test"
then the next likely possibilities are:
1) wrong order of plugins
2) the plugin is missing another plugin that it requires
3) the plugin is incompatible with one of your other plugins
4) the plugin is incompatible with the engine version

all of which are rather tedious to test against.

EDIT:
first make a new project and try to get only that plugin to work there, to test if it is comp0atible with your engine verson
Thanks for the advice - I did a few more tests on my end using ONLY the plugin in a completely fresh project and it worked to load a test battle initially then encountered the error - I'll include my steps below for future reference or anyone else finding this thread.

Additional troubleshooting:

-Opened New Project
-Added plugin to Plugin Manager
-Ran test battle in Database>Troops [Worked]
-Edited the Plugin Settings to match what I had in my main project (Menu row 1, Menu columns 8)
-Ran test battle in Database>Troops [Error encountered]
-Reset the Plugin Settings to what they were initially (Menu row 2, Menu columns 4).
-Ran test battle in Database>Troops [Error encountered]
-removed the plugin from Plugin Manager
-Ran test battle in Database>Troops [Worked]
-Added the plugin back in to the Plugin Manager (without edits)
-Ran test battle in Database>Troops [Error encountered]

At this point I think I'll just forgo having the plugin for the time being and either find a way to fix it later OR find a different plugin -

Thanks for all of the help and advice Andar, much appreciated!
It looks like an error in the plugin: it tries to call isSceneNeedsAdjutGauge for gauge and name sprites, but only defines that method for the former.

Try saving this as a .js file and loading it as a new plugin, after AltMenuScreen2MZ:
JavaScript:
/*:
 * @target MZ
 * @plugindesc Patch for launch plugin AltMenuScreen2MZ - fix crash.
 * @base AltMenuScreen2MZ
 * @orderAfter AltMenuScreen2MZ
 * @author Caethyril
 * @url https://forums.rpgmakerweb.com/threads/159755/
 * @help Free to use and/or modify for any project, no credit required.
 */
Sprite_Name.prototype.isSceneNeedsAdjutGauge = 
  Sprite_Gauge.prototype.isSceneNeedsAdjutGauge;
(This assumes you are using an unedited version of AltMenuScreen2MZ.)

For future reference: a full error trace is generally much more helpful than the concise message. When an error occurs, you can press F8 (or F12 if that fails) to open the dev tools: go to the Console tab, and look for any red text (errors). Typically this will give several lines, describing which functions were called before arriving at the actual error.
@caethyril I added in the above in as a new JS under the plugin and tested in both the clean project and my existing one and that worked! Battles run both in game and in database without the error now.

Thanks a bunch for that, much appreciated!
Great, you're welcome! 👋
Hi. I'm the author of the plugin.
Sorry to bother you because of my careless bug in AltMenuScreen2MZ.js (Ver1.4.0 only)

So I released the latest version(Ver1.5.0) to solve the error. Now you can download it from http://www.moonwhistle.org/tkoolMZ/AltMenuScreen2MZ.zip And it'll be included it as a launch plugin on the next version of RMMZ.

Original thread: https://forums.rpgmakerweb.com/threads/error-when-entering-battles-altmenuscreen2mz-uncaught-typeerror-this-issceneneedsadjustgauge-is-not-a-function.159755/