You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
13 lines
357 B
13 lines
357 B
function onStart(ctx) {
|
|
ctx["hello"] = "Hello, world!" //ctx is an empty object used for passing data between onStart and onStop
|
|
ctx["command"] = demon.commands.add({name: "plugin", callback: (args)=>"Hello, world!"})
|
|
}
|
|
function onStop(ctx) {
|
|
console.log(ctx["hello"].replace("Hello", "Goodbye"))
|
|
ctx["command"]()
|
|
}
|
|
export default {
|
|
onStart,
|
|
onStop
|
|
}
|