Power console performance Debug

rpg-maker-mv-wallpaper-sample.jpg


This plugin is for intermediate level and those who want to get performance index on their event, their common event or their plugin​

How to Use script call- to start, add this line anywhere console.time('mytest')- to end, add this line anywhere console.timeEnd('mytest');- you need to have the rmmv console.log open in background [F8]


- you can use anywhere, and use different name to calculate Subfunction or event or other call


- 1000.000 ms ≈ 1F in rmmv


- after decimal is in 10-6 seconds, µs (1/100000 second)


Compatible scenario


Event and common event


*you can get the ms of a complete event, with multi instance. ex: event run multi CommonEvent
you will get the time performance after all common event will executed.

Spoiler
awfa.jpg

when event with instance Commonevent will end you will get

Spoiler
Sans-titre-2.jpg



You can use it very easy and fast in a multiple context


*Function or inside your plugin


ex:

Spoiler
//code stuff
function myFunction(p1, p2) {
console.time("my factorial test") // start check myFunction performance
//stuff here and test some Methods
console.timeEnd("my factorial test"); // get the performance of myFunction
}



*Other example you want check if your code are faster than another one
try copy this in your console debug

Spoiler
console.time("time for the for in"); // start the for
x = [];
for( var i in $gameParty._items ) {

x.push([i,$gameParty._items]);
}
console.timeEnd("time for the for in"); // end the for

//easy to test in the rmmv console debug
// you will get example 0.054ms , so exaqmple this 054 microsecond µs









Credit and Thanks- no need


Terms
M.I.T



Download


v 1.0 : ConsolePerf.js


you have suggest or issue, your welcome.

Original thread: https://forums.rpgmakerweb.com/threads/power-console-performance-debug.73344/