summaryrefslogblamecommitdiff
path: root/npc/003-2/estard.txt
blob: bd11570ddf0d1b004f9f872cd667376beea9d966 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16















                                            
                                            







                                                                                                                                       

                                                                                          




                                     
                                                                                                                          














                                                                                                                            
                                                                                                      







































































                                                                                                                               






                                               
           
 
                  
                  

        
// Evol scripts.
// Author:
//    Reid
// Description:
//    Light Armor shop keeper.
// Variables:
//    ArtisQuests_Enora
// Values:
//    0    Default.
//    1    BlackSmith quest delivered.
//    2    Chelios Quest given.
//    3    Chelios Quest done.
//    4    BlackSmith gave the sword.
//    5    Light Armor Shop quest delivered.
//    6    Light Armor Shop gave the cloths.

003-2,32,34,0	script	Estard	NPC_PLAYER,{

    function create_party {
        .@party_price = 10000;

        speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
            l("Creating a party has some advantages, it's a pretty good choice!"),
            l("I remember when I created my first party, we were amazed to share some experience with a small group of adventurer..."),
            l("Oh! And our party chat was really entertaining, I do highly recommend you to share this fun as well."),
            lg("The cost to create a party is @@ GP, are you interested?",
               "The cost to create a party is @@ GP, are you interested?", .@party_price);

        if (askyesno() == 1)
        {
            if (Zeny < .@party_price)
            {
                speech S_FIRST_BLANK_LINE | S_LAST_NEXT, l("You don't have enough money, bring me @@ GP.", .@party_price);
            }
            else
            {
                Zeny = Zeny - .@party_price;
                setq General_Janus, 2;
                skill NV_BASIC, 7, 0;

                speech S_FIRST_BLANK_LINE | S_LAST_NEXT, l("Awesome, come back if you ever want to create a larger group!");
            }
        }
    }

   
    function explain_service {
        speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
            l("Welcome to the Town Hall. I am @@, officer in charge of public associations.", .name$),
            l("We offer party and guild certifications and we can also teach you how to use some basic communication skills."),
            l("Do you know how to speak with people around you?");

        if (askyesno() == 2)
        {
            speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
                l("You lack some very basic skills...");

            if (compareandsetq(General_Janus, 0, 1))
            {
                speech S_LAST_NEXT | S_NO_NPC_NAME,
                    l("This book contains everything you should know about it, take it!");

                inventoryplace CommunicationTheory, 1;
                getitem CommunicationTheory, 1;
            }
            else
            {
                speech S_LAST_NEXT | S_NO_NPC_NAME,
                    l("You can read the book that I gave you earlier at the library if you lost it.");
            }
        }
        else
        {
            if (compareandsetq(General_Janus, 0, 1))
            {
                speech S_LAST_NEXT | S_NO_NPC_NAME,
                    l("Anyway."),
                    l("This book contains everything you should know about it, take it!");

                inventoryplace CommunicationTheory, 1;
                getitem CommunicationTheory, 1;
            }

        }

        return;
    }


    speech S_LAST_NEXT,
        lg("Welcome miss.", "Good day sir.");

    do
    {
        // Beta users by-pass check.
        if (getskilllv(NV_BASIC) > 6 && getq(General_Janus) == 1)
        {
            setq General_Janus, 2;
        }

        select
            rif(getq(General_Janus) == 1, l("I would like to create a party.")),
            l("What service do you offer?"),
            menuaction(l("Quit"));

        switch (@menu)
        {
            case 1:
                create_party;
                break;
            case 2:
                explain_service;
                break;
        }
    } while (@menu != 3);

    closedialog;
    goodbye;
    close;

OnInit:
    .@npcId = getnpcid(0, .name$);
    setunitdata(.@npcId, UDT_HEADTOP, 2936);
    setunitdata(.@npcId, UDT_HEADMIDDLE, 1300);
    setunitdata(.@npcId, UDT_HEADBOTTOM, 2204);
    setunitdata(.@npcId, UDT_WEAPON, 1800);
    setunitdata(.@npcId, UDT_HAIRSTYLE, 26);
    setunitdata(.@npcId, UDT_HAIRCOLOR, 0);
    npcsit;

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