summaryrefslogtreecommitdiff
path: root/npc/001-1/trees.txt
blob: c17e00e32b9992cee3d45a8a2f50af2b7cdaab65 (plain) (blame)
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
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
// Evol scripts.
// Author:
//    Travolta
// Description:
//    Invisible tree NPCs for "Lazy Brother" quest
// Variables:
//    AtrilQuests_LazyBrother = 19  -- quest var
//    LazyBrother_TreesLeft = 15    -- how many trees left to search
//    LazyBrother_TreeSearched[15]  -- whether given tree was searched
//    LazyBrother_TreeWithBrother   -- the number of tree where he's hiding
// Quest states:
//    0  - quest not started
//    1  - Katja asked help, searching the trees
//    2  - Bobo is found, "bad" ending
//    3  - player decided to tell Katja where her brother is
//    4  - "good" ending, player helped Katja


function	script	LazyBrotherTreeFunc	{
    .@q = getq(ArtisQuests_LazyBrother);
    if (.@q == 0 || .@q >= 2)
        return;
    .@TreeNum = getarg(0);
    if (LazyBrother_TreeWithBrother == .@TreeNum)
        goto L_FoundHim;
    if (LazyBrother_TreeWithBrother > 0)
    {
        mes l("You search the tree but don't find anybody");
        close2;
        return;
    }
    if (LazyBrother_TreeSearched[.@TreeNum] == 1)
    {
        mes l("You already looked here");
        close2;
        return;
    }
    else
    {
        LazyBrother_TreeSearched[.@TreeNum] = 1;
    }
    .@found = rand(1, LazyBrother_TreesLeft--);
    if (.@found == 1)
    {
        mes l("You found him!");
        LazyBrother_TreeWithBrother = .@TreeNum;
        next;
    }
    else
    {
        mes l("You search the tree but don't find anybody");
        close2;
        return;
    }

L_FoundHim:
    mes l("You notice a young boy sitting on one of the highest branches of the tree.");
    next;
    mes l("He is eating an apple, apparently enjoying it.");
    next;
    select(l("Hey there, are you Bobo, Katja's brother?"));
    mes "";
    mesn "Bobo";
    mesq l("Yes, it's me. It's such a beautiful view from here!");
    next;
    select(l("Your sister sent me to find you. Your mother is worried."));
    mes "";
    mesn "Bobo";
    mesq l("Oh, nooooo... If I go home now, my mum will give me homework.");
    next;
    mesq l("But if you tell my sister, that you didn't find me, I can stay here all day, eating apples and enjoying the view");
    next;
    mesq l("I will give you my pocket money, if you do so.");
    next;
    switch (select(l("A small lie isn't a lie, and I could really use some cash..."),
                   l("I will not lie to a little girl! And your mother needs your help")))
    {
        case 1:
            mes "";
            mesn "Bobo";
            mesq l("Here you go.");
            next;
            mesn "Narrator";
            mes l("Somehow you don't feel good about your deed");
            // Karma -= 2;
            setq ArtisQuests_LazyBrother, 2;
            Zeny += 100;
            getexp 500, 0;
            break;
        case 2:
            mes "";
            mesn "Bobo";
            mesq l("Okay... Tell my sister I'll go home soon.");
            setq ArtisQuests_LazyBrother, 3;
            break;
    }
    LazyBrother_TreesLeft = 0;
    LazyBrother_TreeWithBrother = 0;
    cleararray LazyBrother_TreeSearched,0,15;
    close;
}

001-1,179,30,0	script	#AtrilTree1	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(1);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,177,29,0	script	#AtrilTree2	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(2);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,183,28,0	script	#AtrilTree3	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(3);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,182,25,0	script	#AtrilTree4	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(4);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,187,26,0	script	#AtrilTree5	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(5);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,189,28,0	script	#AtrilTree6	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(6);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,184,30,0	script	#AtrilTree7	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(7);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,189,31,0	script	#AtrilTree8	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(8);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,191,30,0	script	#AtrilTree9	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(9);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,191,33,0	script	#AtrilTree10	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(10);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,187,34,0	script	#AtrilTree11	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(11);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,185,35,0	script	#AtrilTree12	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(12);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,182,34,0	script	#AtrilTree13	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(13);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,180,33,0	script	#AtrilTree14	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(14);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}

001-1,181,32,0	script	#AtrilTree15	NPC_NO_SPRITE,{
    LazyBrotherTreeFunc(15);
    end;
OnInit:
    .sex = G_OTHER;
    .distance = 1;
    end;
}