-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmessages.js
88 lines (67 loc) · 1.84 KB
/
messages.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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
// Game Messages
const helpMessage = `
HELP
----------------------------------------
WizzenBeard, that forgetful old wizard,
has lost his magic hat. Or perhaps it wandered off?
It does seem to have a mind of its own at times...
Help him find it by telling him which way to go.
Don't let him fall into a dark hole or wander off the edge of the map.
Otherwise I fear the magic of the hat may be lost forever...
----------------------------------------
Controls: (type the key, then press enter)
[l] Move Left
[r] Move Right
[u] Move Up
[d] Move Down
[x] Exit Game
[h] Help
Characters: (as seen on the map)
@' WizzenBeard
^ Wizzenbeard's Missing Hat
O dark hole (full of black magic)
Press [Enter] To Continue`;
const gameTitle = `
Help Old WizzenBeard Find His Magic Hat
----------------------------------------`;
const gamePromptMessage = "Which way? [enter [h] for help]";
const gameOverMessage = `
----------------------------------------
GAME OVER.
----------------------------------------
Play Again? [Y | N]`;
const exitGameMessage = `
Thank you for playing Magic Hat.
----------------------------------------
Goodbye!
`;
// Collision Messages
const edgeCollisionMessage = `
Watch out for that...! nevermind.
You fell off the edge!
`;
const holeCollisionMessage = `
"Wuh, wuh, Whoooooooah!"
You fell in a hole.
`;
const hatCollisionMessage = `
"Yippee! I've finally found my magic hat!"
"Now, where did I leave those magic car keys...?"
Congratulations. You helped Old WizzenBeard find his magic hat.
`;
const collisionMessage = {
Edge: edgeCollisionMessage,
Hole: holeCollisionMessage,
Hat: hatCollisionMessage,
};
gameMessage = {
Help: helpMessage,
Title: gameTitle,
Prompt: gamePromptMessage,
"Game Over": gameOverMessage,
Exit: exitGameMessage,
};
module.exports = {
collisionMessage: collisionMessage,
gameMessage: gameMessage,
};