MVCommons - The community core plugin

estriole

Veteran
Veteran
Joined
Jun 27, 2012
Messages
1,309
Reaction score
531
First Language
indonesian
i miss the ACE for pointing which scripts and line that throw error.

i just encounter silly error which apparently only missing ;    >.< (yes... still new in JS) and it's really hard to find it.

can someone add that feature in this plugin. it would be really helpful if we know which plugin crash the game and which line :D .

just suggestion. (if i remember correctly in ACE there's script to backtrace the error... maybe someone could create something like that too?)
 

Zalerinian

Jack of all Errors
Veteran
Joined
Dec 17, 2012
Messages
4,696
Reaction score
935
First Language
English
Primarily Uses
N/A
i miss the ACE for pointing which scripts and line that throw error.

i just encounter silly error which apparently only missing ;    >.< (yes... still new in JS) and it's really hard to find it.

can someone add that feature in this plugin. it would be really helpful if we know which plugin crash the game and which line :D .

just suggestion. (if i remember correctly in ACE there's script to backtrace the error... maybe someone could create something like that too?)
You can get that information by opening the developer console in your game. Simply press F8 in the game client, and it'll open up. It should default to the tab that displays error messages.
 

estriole

Veteran
Veteran
Joined
Jun 27, 2012
Messages
1,309
Reaction score
531
First Language
indonesian
You can get that information by opening the developer console in your game. Simply press F8 in the game client, and it'll open up. It should default to the tab that displays error messages.
it's not clear enough >.<. but at least it's a start. thanks for info...
 

Zalerinian

Jack of all Errors
Veteran
Joined
Dec 17, 2012
Messages
4,696
Reaction score
935
First Language
English
Primarily Uses
N/A
it's not clear enough >.<. but at least it's a start. thanks for info...
Could you please explain what isn't clear enough? Is it the process to open the console, or the error messages themselves?
 

GibzFGC

20+ Year RPG Maker Veteran
Veteran
Joined
Apr 26, 2012
Messages
46
Reaction score
16
First Language
English
Primarily Uses
RMMV
Just a quick mention that line 449 has a comma rather than semi-colon. Look like this atm:

function naturalBoolean(text) { if ( text.match(/(y(es)?)|true|on|active|enabled/gi) ) { return true, } return false; };Should be:

function naturalBoolean(text) { if ( text.match(/(y(es)?)|true|on|active|enabled/gi) ) { return true; } return false; };Just in case anyone else see's this issue in their debugger.
 

Hudell

Dog Lord
Veteran
Joined
Oct 2, 2014
Messages
3,545
Reaction score
3,716
First Language
Java's Crypt
Primarily Uses
RMMZ
Just a quick mention that line 449 has a comma rather than semi-colon. Look like this atm:

function naturalBoolean(text) { if ( text.match(/(y(es)?)|true|on|active|enabled/gi) ) { return true, } return false; };Should be:

function naturalBoolean(text) { if ( text.match(/(y(es)?)|true|on|active|enabled/gi) ) { return true; } return false; };Just in case anyone else see's this issue in their debugger.
Fixed it, thanks :)
 

estriole

Veteran
Veteran
Joined
Jun 27, 2012
Messages
1,309
Reaction score
531
First Language
indonesian
Could you please explain what isn't clear enough? Is it the process to open the console, or the error messages themselves?
the error message of course. :D . but maybe because i'm newb in JS.
 

??????

Diabolical Codemaster
Veteran
Joined
May 11, 2012
Messages
6,513
Reaction score
3,212
First Language
Binary
Primarily Uses
RMMZ
IMO the console is quite a lot of help - especially compared to ace's error stack checking capabilities :/

Edit: I do prefer playtesting with the html file though, and using firefox console instead :)
 
Last edited by a moderator:

Ramiro

Now with an army of Mecha-Ralphs!
Veteran
Joined
Aug 5, 2015
Messages
858
Reaction score
364
First Language
Spanish
the error message of course. :D . but maybe because i'm newb in JS.
That is because javascript has many things different from other languages. SO they can't guess more.

You still have a really good stack trace and things.

That is why using "use strict"; in your code helps, it doesn't improve the stack trace, but it has more clear error messages, because things than are valid on vanilla javascript like getting an undefined property, are not valid on strict javascript:

Code:
var a = { x: 2 };a.y // Without strict a.y returns undefined, but continues, with strict throws the error "Undefined property y".
 

Iavra

Veteran
Veteran
Joined
Apr 9, 2015
Messages
1,797
Reaction score
863
First Language
German
Primarily Uses
Are you sure about that? When i execute this in Chrome's console i get undefined:

Code:
(function() {     "use strict";     var a = {x: 2};     alert(a.y); })();
 

??????

Diabolical Codemaster
Veteran
Joined
May 11, 2012
Messages
6,513
Reaction score
3,212
First Language
Binary
Primarily Uses
RMMZ
same on firefox
 

Ramiro

Now with an army of Mecha-Ralphs!
Veteran
Joined
Aug 5, 2015
Messages
858
Reaction score
364
First Language
Spanish
Are you sure about that? When i execute this in Chrome's console i get undefined:

(function() { "use strict"; var a = {x: 2}; alert(a.y); })();
Hmm oh, it seems than only variables not defined are considered errors:

(function() {  "use strict";  x = 2; // do this;})();That is kinda lame...
 
Last edited by a moderator:

Iavra

Veteran
Veteran
Joined
Apr 9, 2015
Messages
1,797
Reaction score
863
First Language
German
Primarily Uses
No, the error in this case is, that you try to define x as a global variable, which isn't allowed in strict mode.

/edit: If you change this line

Code:
x = a.y; // do this;
to
Code:
var x = a.y; // do this;
or have x defined previously, everything works fine and x gets set to undefined.
 
Last edited by a moderator:

Ramiro

Now with an army of Mecha-Ralphs!
Veteran
Joined
Aug 5, 2015
Messages
858
Reaction score
364
First Language
Spanish
As of version 1.1.0:

  •  Added MVC.naturalBoolean this will return true for many more values than just "true" (that includes on, enabled, yes and y). This will seems "more natural" on config parameters, so that is why it's called naturalBoolean.
As of version 1.2.0:

  • added MVC.degToRad and MVC.radToDeg... so you can convert degrees to radians and vice versa (yes, people sometimes forget how to...)
  • Planning if we should do an MVCommons bugfix library than fixes bugs of the core classes.
Why minor versions and not patch versions?

The add functionality without breaking previous code, so you increment the minor number, fixing bugs is the only way one may add to the patch version.
 
Last edited by a moderator:

Kane Hart

Elmlor.com
Veteran
Joined
Jun 27, 2014
Messages
656
Reaction score
166
First Language
English
Would that mean down the road we have 1000 addons for just bug fixes? That would be a very bad idea. 
 

Hudell

Dog Lord
Veteran
Joined
Oct 2, 2014
Messages
3,545
Reaction score
3,716
First Language
Java's Crypt
Primarily Uses
RMMZ
Would that mean down the road we have 1000 addons for just bug fixes? That would be a very bad idea. 
I thought it would be just a single plugin with fixes for all known bugs. And more importantly: nothing else than bugfixes.
 

Accendor

Veteran
Veteran
Joined
Aug 24, 2015
Messages
227
Reaction score
60
First Language
german
Primarily Uses
N/A
I know that this may sound obvious for some people, but for me it wasn't so I thought I share this information with you:

If you download from Github you apperently have to click the "Raw" button if you want to download the file. In any other case there might be problems with the content of the .js file.

I had this problems here and Zalerinian solved it for me, but if you could just add another instruction in the original post like "Press the Raw button to download and don't use right-click save or anything else" this will probably be helpful for some people :)
 
Last edited by a moderator:

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

Latest Threads

Latest Posts

Latest Profile Posts

"You can thank my later", "But you haven't done anything", "Well, that's why ..."
Are we allowed to post about non-RPG Maker games?
I should realize that error was produced by a outdated version of MZ so that's why it pop up like that
Ami
i can't wait to drink some ice after struggling with my illness in 9 days. 9 days is really bad for me,i can't focus with my shop and even can't do something with my project
How many hours have you got in mz so far?

Forum statistics

Threads
105,884
Messages
1,017,242
Members
137,609
Latest member
shododdydoddy
Top