summaryrefslogtreecommitdiff
path: root/npc/007-1/caelum.txt
blob: 904be5ff02aa0c1c6d02e598e94131175552443a (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
// TMW2 Script
// Author:
//      SkyDragon
//      Saulc
// Reviewer:
//    Jesusalva
// Description:
//    Caelum Miner, main author Skydragon Caelum mean Sky in Latin.
// id:193  MineQuests_Caelum

007-1,143,49,0	script	Caelum	NPC_PLAYER,{
    .@Miner = getq(MineQuest_Caelum);
    if (BaseLevel < 28) goto L_TooWeak;
    if (.@Miner == 1) goto L_Check;
    if (.@Miner == 2) goto L_Complete;

L_GiveTask:
    mesn;
    mesq lg("Hello, wanderer!");
    next;
    mesq l("How did you end up here?");
    next;

    menu
        l("To be honest, I don't know. I was only walking, seeking for adventure!"), L_Quest,
        l("It's none of your business."), L_Quit;


L_Quest:
    mes "";
    mesn;
    mesq l("You perchance said in adventure? Good, because I just hurt my arm while mining!");
    next;
    mesn;
    mesq l("If you bring me some items to I do a bandage and heal myself, I'll give you my gloves!");
    next;

    menu
        l("Really? What do you need?"), L_Start,
        l("Better do this some other time..."), L_Quit;


L_Start:
    setq MineQuest_Caelum, 1;
    mes "";
    mesn;
    mesq l("Ok, what I need is:");
    goto L_List;

L_Quit:
    mes "";
    mesn;
    mesq l("Alright.");
    close;

L_List:
    mes "";
    mesn;
    mes l("Here's what I need:");
    mes l("@@/1 @@", countitem(Lifestone), getitemlink(Lifestone));
    mes l("@@/1 @@", countitem(CottonCloth), getitemlink(CottonCloth));
    mes l("@@/2 @@", countitem(BlackScorpionStinger), getitemlink(BlackScorpionStinger));
    mes l("@@/5 @@", countitem(ScorpionClaw), getitemlink(ScorpionClaw));
    mes l("@@/10 @@", countitem(BatTeeth), getitemlink(BatTeeth));
    mes l("@@/10 @@", countitem(CactusDrink), getitemlink(CactusDrink));
    mes l("@@/20 @@", countitem(MaggotSlime), getitemlink(MaggotSlime));
    mes l("@@/8 @@, just because I'm hungry as a bear.", countitem(BugLeg), getitemlink(BugLeg));
    close;

L_Check:
    mesn;
    mesq l("Did you brought me everything I asked for?");
    next;
    menu
        l("Yes!"), L_Give,
        l("I forgot what you need!"), L_List,
        l("No!"), L_Quit;

L_Give:
    if (
        countitem(Lifestone)            < 1  ||
        countitem(CottonCloth)          < 1  ||
        countitem(BlackScorpionStinger) < 2  ||
        countitem(BugLeg)               < 8  ||
        countitem(BatTeeth)             < 10 ||
        countitem(CactusDrink)          < 10 ||
        countitem(MaggotSlime)          < 20 ||
        countitem(ScorpionClaw)         < 5
        ) goto L_Lying;

    inventoryplace MinerGloves, 1;

    delitem(Lifestone, 1);
    delitem(CottonCloth, 1);
    delitem(BlackScorpionStinger, 2);
    delitem(BugLeg, 8);
    delitem(BatTeeth, 10);
    delitem(CactusDrink, 10);
    delitem(MaggotSlime, 20);
    delitem(ScorpionClaw, 5);

    getitem(MinerGloves, 1);
    getexp(2855, 43);
    setq(MineQuest_Caelum, 2);

    mes "";
    mesn;
    mesq l("Here, all yours. I can't use them like I am now. Thank you.");
    close;

L_Complete:
    mesn;
    mesq l("Wandering too much? Take care to don't get lost.");
    close;

// Funnier to write than to read, but the player lied. :angel:
L_Lying:
    mesn;
    mesq l("No no no, that's wrong.");
    next;
    mesc l("The miner goes to count your stuff again.");
    next;
    mesc l("And again.");
    next;
    mesc l("And again, and again.");
    next;
    mesc l("And again, and again, again.");
    next;
    mesc l("You wonder, maybe he entered on an infinite loop? Hellooo, anybody home?");
    next;
    mesn;
    mesq l("No no no, you don't have everything I've asked for!");
    next;
    goto L_List;

L_TooWeak:
    mesn;
    mesq l("Wanderer, here is dangerous! Go back!");
    close;

OnInit:
    .@npcId = getnpcid(.name$);
    setunitdata(.@npcId, UDT_HEADTOP, MinerHat);
    setunitdata(.@npcId, UDT_HEADMIDDLE, LeatherShirt);
    setunitdata(.@npcId, UDT_HEADBOTTOM, BromenalPants);
    setunitdata(.@npcId, UDT_WEAPON, DeepBlackBoots);
    setunitdata(.@npcId, UDT_HAIRSTYLE, 4);
    setunitdata(.@npcId, UDT_HAIRCOLOR, 3);

    .sex = G_MALE;
    .distance = 4;

    end;
}