summaryrefslogtreecommitdiff
path: root/npc/027-1/luca.txt
blob: 1038bfd41944e89bf1145693420b1892735cd955 (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
// TMW2 script.
// Author:
//    Saulc
//    Jesusalva
// Description:
//    Luca, of Physical Science Class.

027-1,49,102,0	script	Luca	NPC_PLAYER,{
    function basicMagic;
    function standardMagic;
    function advancedMagic;
    if (!MAGIC_LVL) goto L_NoMagic;
    mes l(".:: Physical Sciences Class ::.");
    mesc l("Specialized in skills with weapon-based damage and Assassination.");
    next;
    mesn;
    mesc l("You have @@ magic skill points available.", sk_points());
    select
        l("Basic Tricks"),
        l("Standard Tricks"),
        l("Advanced Tricks");
    mes "";
    .@lv=@menu;
    do
    {
        // Display appropriate menu
        if (.@lv == 1)
            basicMagic();
        else if (.@lv == 2)
            standardMagic();
        else if (.@lv == 3)
            advancedMagic();

        // Handle result
        mes "";
        if (@menuret) {
            if (!learn_magic(@menuret))
                mesc l("You do not meet all requisites for this skill."), 1;
        } else {
            closeclientdialog;
        }

    } while (@menuret);
    close;

L_NoMagic:
    next;
    mesn;
    mesq l("You do not have enough magic power for these classes.");
    next;
    mesn;
    mesq l("Besides the Magic Council, Andrei Sakar have his own Mana Stone, but I doubt he would train the likes of you, or share his Mana Stone.");
    next;
    mesn;
    mesq l("Perhaps, in the city, someone knows rumors about Mana Stones and can teach you. Other than that, you're on your own.");
    close;

function basicMagic {
    if (MAGIC_LVL < 1) goto L_NoMagic;
    mes l(".:: Falkon Punch ::.");
    mesc l("Bash your weapon against your enemies with raised damage and accuracy.");
    mes "";
    mes l(".:: Ground Strike ::.");
    mesc l("Hit the ground, exploding the surroundings and disabling enemies.");
    mes "";
    mes l(".:: Sharpshooter ::.");
    mesc l("Shoot an arrow or bullet which damages everything on its way.");
    mes "";
    menuint
        l("Falkon Punch"), SM_BASH,
        l("Ground Strike"), ASC_METEORASSAULT,
        l("Sharpshooter"), SN_SHARPSHOOTING,
        l("Cancel"), 0;
    return;
}

function standardMagic {
    if (MAGIC_LVL < 2) goto L_NoMagic;
    mes l(".:: Supreme Attack ::.");
    mesc l("Cause a very strong attack with lowered accuracy.");
    mes "";
    mes l(".:: Arrow Shower ::.");
    mesc l("Shoot FIVE arrows or bullets to the air and cause Area Of Effect Damage.");
    mes "";
    menuint
        l("Supreme Attack"), MC_MAMMONITE,
        l("Arrow Shower"), AC_SHOWER,
        l("Cancel"), 0;
    return;
}

function advancedMagic {
    if (MAGIC_LVL < 3) goto L_NoMagic;
    mes l(".:: Counter Attack ::.");
    mesc l("Retaliates next attack with a critical hit. This instance lasts a second.");
    mes "";
    menuint
        l("Counter Attack"), KN_AUTOCOUNTER,
        l("Cancel"), 0;
    return;
}

OnInit:
    .@npcId = getnpcid(.name$);
    setunitdata(.@npcId, UDT_HEADTOP, NPCEyes);
    setunitdata(.@npcId, UDT_HEADMIDDLE, BromenalChest);
    setunitdata(.@npcId, UDT_HEADBOTTOM, JeansShorts);
    setunitdata(.@npcId, UDT_WEAPON, DeepBlackBoots);
    setunitdata(.@npcId, UDT_HAIRSTYLE, 21);
    setunitdata(.@npcId, UDT_HAIRCOLOR, 6);

    .sex = G_MALE;
    .distance = 5;
    end;
}