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
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
|
// TMW2 Scripts
// Author:
// Jesusalva
// Description:
// Celestia Yeti King's quest. Designed so if you're with 4 players, all 4 can
// summon the Yeti King, helping you while doing the quest by themselves.
// setnpcdisplay getarg(0), NPC_YETI_KING
003-1-1,94,21,0 script #YetiKing NPC_SUMMONING_CIRC,{
.@q=getq(HurnscaldQuest_Celestia);
if (.@q > 1 && .@q < 99)
setq HurnscaldQuest_Celestia, 1;
if (.@q == 1 && !.inUse) goto L_Summon;
end;
L_Summon:
dispbottom l("Emoc otem itey gnik!"); // come to me yeti king, spelled backwards. Sorry.
initnpctimer;
end;
L_Die:
percentheal(-100, -100);
npctalk3 l("You're playing with fire. Or ice. Or whatever.");
closedialog;
close;
OnTimer1000:
setnpcdisplay .name$, NPC_YETI_KING;
.inUse=1;
end;
OnTimer2000:
npctalk("Whom dares to disturb my slumber?!");
end;
OnTimer5000:
if (getareausers("003-1-1", 5) < 2) {
npctalk("A lone adventurer? Pft. I'm back to my slumber!");
} else {
npctalk("You're courageous to summon me, I'll give you that.");
areatimer 0, "003-1-1", 93, 20, 97, 25,3000, "#YetiKing::OnSummonTalk";
stopnpctimer;
}
end;
// NPC timer is stopped before reaching here, if it reaches, it means you tried
// to do the quest alone. And this is a Co-Op quest with free player numbers.
// Therefore, we must return the Yeti King to his summon circle.
OnTimer7500:
setnpcdisplay .name$, NPC_SUMMONING_CIRC;
.inUse=0;
stopnpctimer;
end;
// You can only talk to him with SummonTalk. Only one player will summon.
OnSummonTalk:
.@q=getq(HurnscaldQuest_Celestia);
// If you had to return, erase quest progress
if (.@q > 1 && .@q < 99)
setq HurnscaldQuest_Celestia, 1;
if (.@q != 1)
end;
mesn "Dah Yeti King!!";
mesq l("Why do you summon me? Speak.");
mes "";
select
l("I'm sorry, these words just came to my mind."),
l("I did not summon you, I'm just a passer-by. Sorry."),
rif(.@q == 1, l("Celestia asks for your help."));
mes "";
if (@menu == 1)
goto L_Die;
if (@menu == 2)
close;
mesn "Dah Yeti King!!";
mesq l("Yeah yeah yeah, you're not the first one to come talking about that to me.");
next;
mesn "Dah Yeti King!!";
mesq l("My answer is a no, and it'll say like that. Don't test my patience any further.");
next;
select
l("You'll come with me!"),
l("I can prove you my worth!"),
l("Sorry! Sorry!");
mes "";
if (@menu == 1)
goto L_Die;
if (@menu == 2)
close;
mesn "Dah Yeti King!!";
mesq l("Well, then I'll give you a task. We may meet again in Soren Village.");
next;
mesn "Dah Yeti King!!";
mesq l("I'll warp you to the Cave Of Trials. Pass all trials, and meet me on Soren's House. Hahah!");
setq HurnscaldQuest_Celestia, 2;
areatimer 0, "003-1-1", 93, 20, 97, 25, 15000, "#YetiKing::OnWarper";
npctalk l("Listen to me! Whoever wants to follow foolish @@ on their suicide quest, stay here for 15 seconds!", strcharinfo(0));
close;
OnWarper:
// If you had to return, erase quest progress
if (.@q > 2 && .@q < 99)
setq HurnscaldQuest_Celestia, 2;
mes col("Warp to the Cave Of Trials? There is no EXP penalty, but if you die, you need to start everything again!",9);
if (askyesno() == ASK_YES) {
warp "001-6", 27, 180;
}
setnpcdisplay .name$, NPC_SUMMONING_CIRC;
.inUse=0;
closedialog;
close;
OnInit:
.sex = G_OTHER;
.distance = 1;
.inUse=0; // Prevent multiple summons and etc.
end;
}
|