patch a melonJS function
target object
target function
replacement function
// redefine the app.update function with a new oneme.plugin.patch(app, "update", function () { // display something in the console console.log("duh"); // call the original app.update function this._patched();}); Copy
// redefine the app.update function with a new oneme.plugin.patch(app, "update", function () { // display something in the console console.log("duh"); // call the original app.update function this._patched();});
patch a melonJS function