Simple Monkey Patching - v0.5
I am tired of aliasing
The Default Way of Monkey Patching:
class Scene_Base alias monkeypatch_demo_sb_init initialize def initialize monkeypatch_demo_sb_init puts "A Scene Has Been Initiliazed!" endendWhy do we need all these aliases?The Simple Way:
class Scene_Base monkeypatch :initialize do puts "A Scene Has Been Initialized!" endendThis is much better 😎Normal Usages:
Code:
class WhateverClass monkeypatch :method_name do #whatever you want to do ._. endend
Code:
class Scene_Base monkeypatch :initialize, :before do puts "This is called before the original scripts" endend
Installation
get the script here: http://pastebin.com/zgQe4HWH
insert this before all scripts that uses this type of monkey-patching.
Possible Updates
I really don't like the naming of the aliases._.. Maybe I will improve it later.
You still cannot call the original return value._., maybe you can later.
Known Bugs
Currently None, but there is a high possibility that there are some >_>
Terms of Use
You can repost this anywhere else without my permission.
You can modify the script as long as you keep my name on it.
Credit Me.