mirror of https://github.com/NovaGM/Modules.git
Added Cumcord loader plugin
This commit is contained in:
parent
c44edd8009
commit
95c68f2eb1
|
@ -0,0 +1,11 @@
|
|||
{
|
||||
"main": "index.js",
|
||||
|
||||
"name": "CumcordLoader",
|
||||
"description": "Loads Cumcord.",
|
||||
"tags": ["mod"],
|
||||
|
||||
"authors": ["465702500146610176"],
|
||||
|
||||
"version": "1.0.0"
|
||||
}
|
|
@ -0,0 +1,21 @@
|
|||
import showToast from "@goosemod/toast";
|
||||
|
||||
function reqListener() {
|
||||
eval(this.responseText);
|
||||
showToast("Cumcord has injected.");
|
||||
}
|
||||
|
||||
export default {
|
||||
goosemodHandlers: {
|
||||
onImport: () => {
|
||||
var oReq = new XMLHttpRequest();
|
||||
oReq.addEventListener("load", reqListener);
|
||||
oReq.open("GET", "https://raw.githubusercontent.com/Cumcord/Cumcord/stable/dist/build.js");
|
||||
oReq.send();
|
||||
},
|
||||
onRemove: () => {
|
||||
window.cumcord.uninject();
|
||||
showToast("Cumcord has been uninjected.");
|
||||
}
|
||||
}
|
||||
};
|
Loading…
Reference in New Issue