Help with error

Nightfight

Villager
Member
Joined
Jan 21, 2020
Messages
29
Reaction score
3
First Language
English
Primarily Uses
RMMV
I exported my game and sent it to a friend. When he opens he gets a screen saying Reference errors, but I can open it fine. Can anyone help? thx
 

Nightfight

Villager
Member
Joined
Jan 21, 2020
Messages
29
Reaction score
3
First Language
English
Primarily Uses
RMMV
To be more specific, the error says newstate is not defined
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,825
Reaction score
12,235
First Language
English
Primarily Uses
RMMV
Can you please get a screenshot from your friend? Does this error happen as soon as he launches the game? Or does he get to the title screen and take some action (and if so, what action)?

Also a screenshot of your plugin manager (or several, if you have more than one screen worth).

Is this the first time you've given the game to your friend? Any chance he had a previous version and is trying to load a game he started in one of those versions?
 

MushroomCake28

KAMO Studio
Global Mod
Joined
Nov 18, 2015
Messages
2,617
Reaction score
3,791
First Language
English
Primarily Uses
RMMV

@Nightfight , please avoid double posting, as it is against the forum rules. You can review our forum rules here. Thank you.


Since it's working on your end and not on your friend's end I will assume for that this is an issue with deployment. I will move the thread according to the root of the issue.

I've moved this thread to RPG Maker MV Deployment. Please be sure to post your threads in the correct forum next time. Thank you.

 

Nightfight

Villager
Member
Joined
Jan 21, 2020
Messages
29
Reaction score
3
First Language
English
Primarily Uses
RMMV
Can you please get a screenshot from your friend? Does this error happen as soon as he launches the game? Or does he get to the title screen and take some action (and if so, what action)?

Also a screenshot of your plugin manager (or several, if you have more than one screen worth).

Is this the first time you've given the game to your friend? Any chance he had a previous version and is trying to load a game he started in one of those versions?
of course here:
also ik double post but i want to resolve this issue
Its when he hits game exe
He has not opened it before
This is the file i send also
 

Attachments

Last edited:

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,825
Reaction score
12,235
First Language
English
Primarily Uses
RMMV
And the other things I asked?

Instead of double posting, just edit your post and add the extra info, if nobody else has replied yet.
 

Nightfight

Villager
Member
Joined
Jan 21, 2020
Messages
29
Reaction score
3
First Language
English
Primarily Uses
RMMV
And the other things I asked?

Instead of double posting, just edit your post and add the extra info, if nobody else has replied yet.
ok did it
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,825
Reaction score
12,235
First Language
English
Primarily Uses
RMMV
Maybe read my post again. Can't help until you give me all the information. There are at least 2 other things I asked for that you haven't provided or answered.
 

Nightfight

Villager
Member
Joined
Jan 21, 2020
Messages
29
Reaction score
3
First Language
English
Primarily Uses
RMMV
Maybe read my post again. Can't help until you give me all the information. There are at least 2 other things I asked for that you haven't provided or answered.
now it there (dang it. I hate double posting rule and break it, but how else r u supposed to know)
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,825
Reaction score
12,235
First Language
English
Primarily Uses
RMMV
okay - double posting means posting twice in a row. If the last post is not yours, you can go ahead and post. If the last post is yours, you should edit it instead of posting again.

That is not your plugin manager.

Is this the first build you have given your friend? Did he have an earlier build and might have saved a game in that version?
 

Nightfight

Villager
Member
Joined
Jan 21, 2020
Messages
29
Reaction score
3
First Language
English
Primarily Uses
RMMV
okay - double posting means posting twice in a row. If the last post is not yours, you can go ahead and post. If the last post is yours, you should edit it instead of posting again.

That is not your plugin manager.

Is this the first build you have given your friend? Did he have an earlier build and might have saved a game in that version?
yeah he has an old build I told him to delete it didn't work
here is plugin manager
 

Attachments

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,825
Reaction score
12,235
First Language
English
Primarily Uses
RMMV
He may also need to delete any save files.

I am thinking you gave him your game, which he played and made one or more save files. Then you worked on the game some more, adding at least one plugin. Now when he plays it, that plugin is looking for a newState variable in the save files, and his save files don't have it because the plugin wasn't part of the game when he saved.

So two things you can do ...

Get him to delete the save files and then try to play the game.

Look at the code of all your plugins (luckily you don't have many) and see which one contains the word newState (case is important). This will not solve it, but it will identify that it IS a plugin issue and confirm my suspected reason.


edit: I believe the error is coming from the MouseSystem plugin. My guess is that your friend has a gamepad connected, and you do not. The aliased _updateGamepadState uses a variable called newState but does not define it. The original function defines it. But local variables in the original function are not available to the aliased function afaik, so I think this is a bug with the plugin.

The quick solution is to have your friend disconnect his gamepad. But you should look for a fix for this, or use a different mouse plugin.

That plugin actually says it requires TacticsSystem.js and you don't have that in your project at all. Why do you have the mouse system plugin?
 
Last edited:

Nightfight

Villager
Member
Joined
Jan 21, 2020
Messages
29
Reaction score
3
First Language
English
Primarily Uses
RMMV
He may also need to delete any save files.

I am thinking you gave him your game, which he played and made one or more save files. Then you worked on the game some more, adding at least one plugin. Now when he plays it, that plugin is looking for a newState variable in the save files, and his save files don't have it because the plugin wasn't part of the game when he saved.

So two things you can do ...

Get him to delete the save files and then try to play the game.

Look at the code of all your plugins (luckily you don't have many) and see which one contains the word newState (case is important). This will not solve it, but it will identify that it IS a plugin issue and confirm my suspected reason.


edit: I believe the error is coming from the MouseSystem plugin. My guess is that your friend has a gamepad connected, and you do not. The aliased _updateGamepadState uses a variable called newState but does not define it. The original function defines it. But local variables in the original function are not available to the aliased function afaik, so I think this is a bug with the plugin.

The quick solution is to have your friend disconnect his gamepad. But you should look for a fix for this, or use a different mouse plugin.

That plugin actually says it requires TacticsSystem.js and you don't have that in your project at all. Why do you have the mouse system plugin?
thanks the error was fixed
it was the mouse one which made it so when my friend plugged in a controller it wouldnt work
without a controller plugged in it works fine
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,825
Reaction score
12,235
First Language
English
Primarily Uses
RMMV
If you want players to be able to use a controller, you'll need to get it fixed.

It might still pay to report the issue to the plugin creator, because that bit of code is only called when there IS a controller plugged in. So they have catered for people wanting to use one, but those are the people who will experience the crash.

And also, why do you even have that plugin? It specifically says it's to support another plugin that you're not using, so there's no point in having it. And it might cause other issues because you don't have the required plugin that it lists.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

My sister is a saint. Specifically Saint Peter. Because shes my best friend until other ppl are around then shes all "nope, dont know him, dont like him."
Making it a rule that I don't do any world building for my new game before the actual gameplay is concrete and working. I have 16 years of lore to work with anyway.
Cheesy power metal makes everything better. No matter what you do, you'll feel heroic doing it.
Starting to really like the first of my madness areas. I think the eyes looking at them really helps to sell the place. :LZSexcite:

Forum statistics

Threads
95,698
Messages
931,109
Members
126,043
Latest member
rpgteck
Top