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
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
|
//===== eAthena Script =======================================
//= Cooking Quest
//===== By: ==================================================
//= Reddozen
//===== Current Version: =====================================
//= 1.5a
//===== Compatible With: =====================================
//= eAthena 1.0+
//===== Description: =========================================
//= Official Cooking Quest
//===== Additional Comments: =================================
//= 1.1 Fixed wrong item ID, added missing ";, optimized [Lupus]
//= 1.1a minor bugfix, thx 2 Irmin [Lupus]
//= 1.2 Fixed exploit, some typos [Lupus]
//= 1.3 Fixed wrong label [Lupus] 1.3a updated to Reddozen's changes
//= 1.3b Fixed wrong id, fixed Puch quest, added more Pouch Quest
//= dialogues [Lupus]
//= 1.4 Fixed spelling, added some dialoguesm optimized
//= fixed bugs. Tested, fully working [Lupus]
//= 1.5 More fixes [Lupus]
//============================================================
prt_castle.gat,43,30,6 script Chef Apprentice 878,{
mes "[Chef's Apprentice]";
if(cooking == 1) goto L_Remind;
if(cooking == 2){
mes "I see you passed the test.";
mes "Good job!";
next;
mes "[Chef's Apprentice]";
mes "This book would be quite helpful for a novice chef.";
getitem 7472, 1;//Items: Lv1 Cookbook,
set cook_book, 7472;
set cooking, 3;
close;
}
if(cooking == 3){
mes "Hi there. Is there something";
mes "that I can help you with?";
next;
menu "Buy Supplies",M_BuySupply, "Talk about cooking",L_Cook_Talk, "Leave",L_No_Talk;
M_BuySupply:
mes "[Chef's Apprentice]";
mes "Outdoor Cooking Set - 500z each";
mes " How many?";
input @amount;
if(@amount < 1) goto ER_Invalid;
if(@amount > 100) goto ER_TooMuch;
if(@amount*500 > Zeny) goto ER_Zeny;
set Zeny, Zeny-(@amount*500);
getitem 12125, @amount;//Items: Outdoor Cooker,
next;
mes "[Chef's Apprentice]";
mes "Enjoy!";
close;
L_Cook_Talk:
mes "[Chef's Apprentice]";
mes "You passed the test,";
mes "but were your results";
mes "worth while?";
next;
menu "Taste my food",-, "No, it was horrible",L_Taste_End;
mes "[Chef's Apprentice]";
mes "I don't know about that.";
mes "It may not be safe...";
next;
menu "Please taste it",-, "You're probably right",L_Taste_End;
mes "[Chef's Apprentice]";
mes "Why would I want to try";
mes "the food of a novice chef?";
next;
menu "Please try",-, "Yeah, I'm too new at this",L_Taste_End;
mes "[Chef's Apprentice]";
mes "I'll make a deal with you.";
mes "if you cook me one of every";
mes "Lv 1 food, then I'll try";
mes "your Cooking...";
next;
menu "Agree",-, "Refuse",L_Taste_End;
mes "[Chef's Apprentice]";
mes "You'll need to make all";
mes "six foods. Let me know";
mes "when you're finished.";
set cooking, 4;
close;
L_Taste_End:
mes "[Chef's Apprentice]";
mes "Come back when you feel";
mes "more confident.";
close;
L_No_Talk:
mes "[Chef's Apprentice]";
mes "Come back to vist anytime!";
mes "Have a good day.";
close;
}
if(cooking == 4){
if(countitem(12056)
&& countitem(12061)
&& countitem(12046)
&& countitem(12066)
&& countitem(12041)
&& countitem(12051)) {//Items: Frog Spawn Soup, Grape Juice with Honey, Grape Juice and Tea, Fried Monkey Tail, Boiled Locust, Steamed Crab Pincer,
delitem 12056, 1;//Items: Frog Spawn Soup,
delitem 12061, 1;//Items: Grape Juice with Honey,
delitem 12046, 1;//Items: Grape Juice and Tea,
delitem 12066, 1;//Items: Fried Monkey Tail,
delitem 12041, 1;//Items: Boiled Locust,
delitem 12051, 1;//Items: Steamed Crab Pincer,
mes "What!? Through already?";
mes "Let me see what you've made";
next;
mes "[Chef's Apprentice]";
mes "Great job, but there's";
mes "still one thing that I need";
mes "you to do. Talk to a friend";
mes "of mine in Payon. We used";
mes "to study together.";
next;
mes "[Chef's Apprentice]";
mes "Take him this ^000080Leather Pouch^000000,";
mes "and I'll put in a good word";
mes "for you with my teacher.";
getitem 7432, 1;//Items: Leather Pouch,
set cooking, 5;
} else {
mes "Please come back when you've cooked";
mes "all the Lv 1 foods.";
next;
menu "Buy Supplies",M_BuySupply, "Leave",L_No_Talk;
}
close;
}
if(cooking == 5){
mes "Please, don't forget to";
mes "hand my ^000080Leather Pouch^000000";
mes "to my friend in Payon.";
next;
mes "[Chef's Apprentice]";
mes "Well... Is there something";
mes "that I can help you with?";
next;
menu "Buy Supplies",-, "Leave",L_No_Talk2;
mes "[Chef's Apprentice]";
mes "Outdoor Cooking Set - 500z each.";
mes " How many?";
input @amount;
if(@amount < 1) goto ER_Invalid;
if(@amount > 100) goto ER_TooMuch;
if(@amount*500 > Zeny) goto ER_Zeny;
set Zeny, Zeny-(@amount*500);
getitem 12125, @amount;//Items: Outdoor Cooker,
next;
mes "[Chef's Apprentice]";
mes "Enjoy!";
close;
L_No_Talk2:
mes "[Chef's Apprentice]";
mes "Come back to vist anytime!";
mes "Have a good day.";
close;
}
if(cooking == 6){
mes "Thank you for taking that";
mes "pouch to my friend! Take";
mes "this as a gift.";
set cooking, 7;
getitem 12126, 10;//Items: Home Cooking Set,
next;
mes "[Chef's Apprentice]";
mes "Come back later if you";
mes "need anything else!";
close;
}
if(cooking == 7){
mes "Welcome back. What";
mes "would you like to do?";
next;
menu "Buy Supplies",-, "Just visiting",L_Leave3;
mes "[Chef's Apprentice]";
mes "What would you like?";
next;
menu "Outdoor Cooking Set - 500z each",-, "Home Cooking Set - 1,000z",L_HomeCooking, "Never Mind",L_Leave3;
set @price, 500;
set @tool, 12125;
goto L_Cooking_Tools4;
L_HomeCooking:
set @price, 1000;
set @tool, 12126;
L_Cooking_Tools4:
mes "[Chef's Apprentice]";
mes " How many?";
input @amount;
if(@amount < 1) goto ER_Invalid;
if(@amount > 100) goto ER_TooMuch;
if(@amount*@price > Zeny) goto ER_Zeny;
set Zeny, Zeny-(@amount*@price);
getitem @tool, @amount;
next;
mes "[Chef's Apprentice]";
mes "Enjoy!";
close;
L_Leave3:
mes "[Chef's Apprentice]";
mes "Come back to vist anytime!";
mes "Have a good day.";
close;
}
mes "Hi there. What can I";
mes "do for you?";
next;
menu "Just looking around",-, "I want to learn to cook",ap_2;
mes "[Chef's Apprentice]";
mes "Feel free to look around";
mes "as much as you like.";
mes "Just don't disturb my";
mes "teacher.";
close;
ap_2:
if(baseLevel < 50){
mes "[Chef's Apprentice]";
mes "You should train a little";
mes "more before trying something";
mes "as hard as cooking";
close;
}
set cooking, 1;
mes "[Chef's Apprentice]";
L_Remind:
mes "So you want to learn to";
mes "cook huh? Well, if you";
mes "think you can handle it,";
mes "just talk to my teacher.";
next;
mes "[Chef's Apprentice]";
mes "Just don't forget your";
mes "^000080Chef's Hat^000000 or Sharle";
mes "will yell at you.";
close;
ER_Zeny:
next;
mes "[Chef's Apprentice]";
mes "You don't have enough zeny.";
close;
ER_TooMuch:
next;
mes "[Chef's Apprentice]";
mes "You can't by that much at a time!.";
mes "You don't have to buy it all at once.";
close;
ER_Invalid:
next;
mes "[Chef's Apprentice]";
mes "You can't buy negative amounts of cooking";
mes "equipment. Please buy a valid amount.";
close;
}
payon.gat,209,127,4 script Cooking Friend 88,{
mes "[Cooking Friend]";
if(cooking == 5){
if(countitem(7432)) {
delitem 7432, 1;//Items: Leather Pouch,
mes "I see my friend sent you";
mes "to give me something.";
set cooking, 6;
emotion e_thx;
} else {
mes "What? My friend sent you";
mes "just to say Hello?";
emotion e_hmm;
}
mes "Thank you for your";
mes "trouble. Tell him I said,";
mes "Hello.";
close;
}
mes "Hello, how are you?";
close;
}
prt_castle.gat,45,35,4 script Sharle 886,{
mes "[Sharle]";
if(cooking && getequipid(1) != 5026) goto L_No_Uniform; //Item: Chef's Hat
if(cooking == 7)goto L_Cooking_7;
if(first_cooking)goto L_First_Cooking;
if(cooking == 1){
mes "So you want to learn how to cook?";
next;
menu "Yes",M_GetQuest, "No",M_End;
}
mes "What a great day to bake some";
mes "wonderfull treats!";
close;
M_GetQuest:
mes "[Sharle]";
mes "Ok. Let's try to cook something together.";
set first_cooking,rand(1,6);
L_First_Cooking:
mes "I'm lack of special ingredients,";
mes "bring me:";
if(first_cooking == 1){
set @item1, 577;
set @item1a, 1;
set @item2, 908;
set @item2a, 10;
set @item3, 1024;
set @item3a, 1;
set @food1, 12056;
mes "1 Grain, 10 Spawn, and";
mes "1 Squid Ink.";
}
if(first_cooking == 2){
set @item1, 518;
set @item1a, 1;
set @item2, 514;
set @item2a, 2;
set @item3, 501;
set @item3a, 1;
set @food1, 12061;
mes "1 Honey, 2 Grapes, and";
mes "1 Red Potion.";
}
if(first_cooking == 3){
set @item1, 514;
set @item1a, 3;
set @item2, 501;
set @item2a, 2;
set @item3, 0;
set @item3a, 0;
set @food1, 12046;
mes "3 Grapes and 2 Red Potions.";
}
if(first_cooking == 4){
set @item1, 942;
set @item1a, 5;
set @item2, 7031;
set @item2a, 1;
set @item3, 7457;
set @item3a, 1;
set @food1, 12066;
mes "5 Yoyo Tails, 1 Old Frying Pan, and";
mes "1 Cooking Oil.";
}
if(first_cooking == 5){
set @item1, 940;
set @item1a, 5;
set @item2, 7031;
set @item2a, 1;
set @item3, 7457;
set @item3a, 1;
set @food1, 12041;
mes "5 Grasshopper Legs, 1 Old Frying Pan, and";
mes "1 Cooking Oil.";
}
if(first_cooking == 6){
set @item1, 960;
set @item1a, 10;
set @item2, 511;
set @item2a, 10;
set @item3, 503;
set @item3a, 1;
set @food1, 12051;
mes "10 Nippers, 10 Green Herbs, and";
mes "1 Yellow Potion.";
}
if(countitem(@item1) < @item1a || countitem(@item2) < @item2a || countitem(@item3) < @item3a) close;
delitem @item1, @item1a;
delitem @item2, @item2a;
delitem @item3, @item3a;
next;
set cooking, 2;
mes "[Sharle]";
mes "Great Job!";
mes "You can now purchase";
mes "Outdoor Cooking Sets.";
getitem @food1, 1;
set first_cooking, 0;
close;
L_Cooking_7:
mes "Would you like to check";
mes "out my ^800000Cookbooks^000000?";
next;
menu "Yes",-, "No", M_End2, "Return Book", M_ReturnBook;
mes "[Sharle]";
if(cook_book){
mes "You'll have to give me back the";
mes "first book I loaned you if you";
mes "would like to check out a new book.";
mes "Would you like to trade books?";
next;
menu "Yes",-, "No",M_End2;
if(countitem(cook_book)==0){
mes "What? You don't have the book I loaned you?";
mes "It was a ^800000"+getitemname(cook_book)+"^000000.";
emotion e_sry;
close;
}
}
mes "[Sharle]";
mes "Which book would you like?";
next;
menu "^800000Lv 1 Cookbook",b_1, "Lv 2 Cookbook",b_2, "Lv 3 Cookbook",b_3, "Lv 4 Cookbook",b_4, "Lv 5 Cookbook",b_5, "^000000Leave",M_End2;
b_1:
mes "[Sharle]";
mes "You will need:";
mes "10 Pumpkins";
next;
if(countitem(535) < 10) goto L_No_Items;//Items: Pumpkin,
delitem 535, 10;//Items: Pumpkin,
set @checkout, 7472;
mes "And I see you have";
mes "what you need!";
next;
goto b_trade;
b_2:
mes "[Sharle]";
mes "You will need:";
mes "5 well-baked cookies";
next;
if(countitem(538) < 5) goto L_No_Items;//Items: Well-baked Cookie,
delitem 538, 5;//Items: Well-baked Cookie,
set @checkout, 7473;
mes "And I see you have";
mes "what you need!";
next;
goto b_trade;
b_3:
mes "[Sharle]";
mes "You will need:";
mes "5 Sushi";
next;
if(countitem(551) < 5) goto L_No_Items;//Items: Sushi,
delitem 551, 5;//Items: Sushi,
set @checkout, 7474;
mes "And I see you have";
mes "what you need!";
next;
goto b_trade;
b_4:
mes "[Sharle]";
mes "You will need:";
mes "5 Baos";
next;
if(countitem(553) < 5) goto L_No_Items;//Items: Bao,
delitem 553, 5;//Items: Bao,
set @checkout, 7475;
mes "And I see you have";
mes "what you need!";
next;
goto b_trade;
b_5:
mes "[Sharle]";
mes "You will need:";
mes "10 shoots";
next;
if(countitem(711) < 10) goto L_No_Items;//Items: Shoot,
delitem 711, 10;//Items: Shoot,
set @checkout, 7476;
mes "And I see you have";
mes "what you need!";
next;
goto b_trade;
b_trade:
mes "[Sharle]";
mes "If you find you need a new book,";
mes "you're welcome to come back and";
mes "trade.";
if(cook_book){
if(countitem(cook_book)==0){
mes "What? You don't have the book I loaned you?";
mes "It was a ^800000"+getitemname(cook_book)+"^000000.";
emotion e_sry;
close;
}
delitem cook_book,1;
mes "Have fun, and good luck!";
} else {
mes "Good luck! I hope you learn a lot!";
}
getitem @checkout,1;
set cook_book, @checkout;
close;
M_End:
mes "[Sharle]";
mes "That's fine with me, come back";
mes "when you want to cook.";
close;
M_End2:
mes "[Sharle]";
mes "Well, I'm here whenever you'd like";
mes "to learn. Just make sure you're";
mes "ready.";
close;
M_ReturnBook:
if(cook_book == 0){
mes "[Sharle]";
mes "You haven't borrowed any books.";
emotion e_hmm;
close;
}
if(countitem(cook_book)==0){
mes "What? You don't have the book I loaned you?";
mes "It was a ^800000"+getitemname(cook_book)+"^000000.";
emotion e_sry;
close;
}
delitem cook_book,1;
set cook_book, 0;
mes "[Sharle]";
mes "Returning the book already?";
mes "did you learn what you wanted";
mes "to know?";
emotion e_what;
close;
L_No_Items:
mes "[Sharle]";
mes "So come back when";
mes "you have the items";
mes "that you need.";
close;
L_No_Uniform:
mes "How dare you disrespect me";
mes "by showing up out of uniform.";
mes "Come back when you have your";
mes "uniform on.";
emotion e_bzz;
close;
}
|