summaryrefslogtreecommitdiff
path: root/world/map/npc/functions/evil_obelisk.txt
blob: a5fe6e552e3f074c8c1b7fccca45e15961d82bb4 (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
function|script|EvilObelisk
{
    mes "[Evil Obelisk]";
    mes "(A mystical aura surrounds this stone. It seems to crave money.)";
    next;

    set @cost_jacko, 6500;
    set @cost_gy1, 4000;
    set @cost_gy2, 3000;
    set @cost_skull, 2800;
    set @cost_snake, 2500;
    set @cost_keshlam, 10000;

    menu
        "Don't pay it anything.", L_Close,
        "Pay it " + @cost_jacko + " gold.", L_JACKO,
        "Pay it " + @cost_gy1 + " gold.", L_GRAVEYARD1,
        "Pay it " + @cost_gy2 + " gold.", L_GRAVEYARD2,
        "Pay it " + @cost_skull + " gold.", L_SKULL,
        "Pay it " + @cost_snake + " gold.", L_SNAKE,
        "Pay it " + @cost_keshlam + " gold.", L_KESHLAM;

L_JACKO:
    if (Zeny < @cost_jacko)
        goto L_NotEnough;
    set Zeny, Zeny - @cost_jacko;
    set @mob_id, 1022;
    set @mob_count, rand(1,2);
    goto L_Summon;

L_GRAVEYARD1:
    if (Zeny < @cost_gy1)
        goto L_NotEnough;
    set @temp, rand(2);
    if(@temp == 0)
        set @mob_id, 1036;  // Zombie
    if(@temp == 1)
        set @mob_id, 1045;  // Fallen
    set @mob_count, rand(1,2);
    set Zeny, Zeny - @cost_gy1;
    goto L_Summon;

L_GRAVEYARD2:
    if (Zeny < @cost_gy2)
        goto L_NotEnough;
    set @temp, rand(2);
    if(@temp == 0)
        set @mob_id, 1044;  // Lady Skelly
    if(@temp == 1)
        set @mob_id, 1043;  // Normal Skelly
    set @mob_count, rand(1,2);
    set Zeny, Zeny - @cost_gy2;
    goto L_Summon;

L_SKULL:
    if (Zeny < @cost_skull)
        goto L_NotEnough;
    set @temp, rand(2);
    if(@temp == 0)
        set @mob_id, 1024;  // Poison
    if(@temp == 1)
        set @mob_id, 1023;  // Fire
    set @mob_count, rand(1,4);
    set Zeny, Zeny - @cost_skull;
    goto L_Summon;

L_SNAKE:
    if (Zeny < @cost_snake)
        goto L_NotEnough;
    set @temp, rand(4);
    if(@temp == 0)
        set @mob_id, 1034;  // Grass
    if(@temp == 1)
        set @mob_id, 1026;  // Mnt.
    if(@temp == 2)
        set @mob_id, 1010;  // Normal
    if(@temp == 3)
        set @mob_id, 1021;  // Cave
    set @mob_count, rand(1,4);
    set Zeny, Zeny - @cost_snake;
    goto L_Summon;

L_KESHLAM:
    if (Zeny < @cost_keshlam)
        goto L_NotEnough;
    set @temp, rand(3);
    if(@temp == 0)
        set @mob_id, 1140;  // Tengu
    if(@temp == 1)
        set @mob_id, 1141;  // Sasquatch
    if(@temp == 2)
        set @mob_id, 1143;  // Mana Slayer
    set @mob_count, rand(1,3);
    set Zeny, Zeny - @cost_keshlam;
    goto L_Summon;

L_Summon:
    areamonster @map$, @x0, @y0, @x1, @y1, "", @mob_id, @mob_count;
    goto L_Close;

L_NotEnough:
    mes "You don't have that much money";
    goto L_Close;

L_Close:
    set @cost_jacko, 0;
    set @cost_gy1, 0;
    set @cost_gy2, 0;
    set @cost_skull, 0;
    set @cost_snake, 0;
    set @cost_keshlam, 0;
    return;

}