-
Notifications
You must be signed in to change notification settings - Fork 12
/
eventUpdater.js
59 lines (53 loc) · 1.86 KB
/
eventUpdater.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
const event = require("./events.json");
const eventStatus = require("./eventStatus.json")
const fs = require("fs");
module.exports = {
avalanche: function A() {
event.N = "Avalanche"
event.C = eventStatus.AC;
event.icon = eventStatus.AE1;
event.E2 = eventStatus.AE2;
event.D = eventStatus.AD;
fs.writeFile("./events.json", JSON.stringify(event), (err) => console.error);
},
stars: function S() {
event.N = "Star allign"
event.C = eventStatus.SC;
event.icon = eventStatus.SE1;
event.E2 = eventStatus.SE2;
event.D = eventStatus.SD;
fs.writeFile("./events.json", JSON.stringify(event), (err) => console.error);
},
tornado: function T() {
event.N = "Tornado"
event.C = eventStatus.TC;
event.icon = eventStatus.TE1;
event.E2 = eventStatus.TE2;
event.D = eventStatus.TD;
fs.writeFile("./events.json", JSON.stringify(event), (err) => console.error);
},
moon: function FM() {
event.N = "Full moon"
event.C = eventStatus.FMC;
event.icon = eventStatus.FME1;
event.E2 = eventStatus.FME2;
event.D = eventStatus.FMD;
fs.writeFile("./events.json", JSON.stringify(event), (err) => console.error);
},
fstars: function FS() {
event.N = "Falling stars"
event.C = eventStatus.FSC;
event.icon = eventStatus.FSE1;
event.E2 = eventStatus.FSE2;
event.D = eventStatus.FSD;
fs.writeFile("./events.json", JSON.stringify(event), (err) => console.error);
},
eclypse: function E() {
event.N = "Eclypse"
event.C = eventStatus.EC;
event.icon = eventStatus.EE1;
event.E2 = eventStatus.EE2;
event.D = eventStatus.ED;
fs.writeFile("./events.json", JSON.stringify(event), (err) => console.error);
}
};