你正在訪問的內容是外部程式的映像位址,僅用於使用者加速訪問,本站無法保證其可靠性。當前的連結位址(單點即可複製)為 https://greasyfork.org.cn/zh-CN/scripts/521490-definable-modmenu,源站連結 點此以跳轉。
Definable is a modular ModMenu for Drawaria.Online
当前为
Definable, as said in the Title, is aimed to be a modular ModMenu for the Online Game Drawaria.Online. It also is the successor of Cubic Engine. As much as I liked that project, it got a little "overwhelming" since I wrote a lot of gibberish back then... ;P
After the site has loaded a Custom Event will be dispatched on the window Object. The detail attribute of the Custom Event will contain a reference to the Main Component and a reference to the Base/Core Class to allow for easy access to create new SubModules. This Event will most likely be dispatched after approximately 1 second depending on how fast you internet connection is. After Definable has finished initializing it will automatically load all available SubModules.
A SubModule can be easily created. For this download the default source code. The Custom Event at initialization will contain a reference to the Main Object and a reference to the Base/Core Class to be used with the extends keyword.
For Example:
window.addEventListener("definable:init",function(event) {
const core = event.detail.core;
class BigBrush extends core {
constructor() {
super("BigBrush","pencil");
}
/*
...
*/
}
})
Optionally you can also just invoke the core Class directly by instead doing:
window.addEventListener("definable:init",function(event) {
const core = event.detail.core;
const BigBrush = new core("BigBrush","pencil");
})