summaryrefslogblamecommitdiff
path: root/npc/items/emptybox.txt
blob: 558733156d0da998be7795421ae5c8bfabfa82d1 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12











                                                          
                                                 






                                                   
                                                          





                                                              



                                 


                                   

                                   

                               

                                  







                                    
// TMW2 scripts.
// Authors:
//    Jesusalva
// Description:
//    Allows to mount your own fish/plushroom/croconut box

000-0,0,0,0	script	Empty Box#it	NPC_HIDDEN,{
    close;

OnUse:
    mesn;
    mesc l("You can fill this box with the following:");
    mesc l("- @@ @@", 7, getitemlink(GrassCarp));
    mesc l("- @@ @@", 17, getitemlink(Croconut));
    mesc l("- @@ @@", 20, getitemlink(CommonCarp));
    mesc l("- @@ @@", 87, getitemlink(Plushroom));
    mes "";
    mesc l("Fill with what?");
    select
        l("Don't fill"),
        rif(countitem(GrassCarp) >= 7, l("7 Grass Carp")),
        rif(countitem(Croconut) >= 17, l("17 Croconut")),
        rif(countitem(CommonCarp) >= 20, l("20 Common Carp")),
        rif(countitem(Plushroom) >= 87, l("87 Plushroom"));
    mes "";
    switch (@menu) {
        case 2:
            delitem GrassCarp, 7;
            getitem FishBox, 1;
            break;
        case 3:
            delitem Croconut, 17;
            getitem CroconutBox, 1;
            break;
        case 4:
            delitem CommonCarp, 20;
            getitem FishBox, 1;
            break;
        case 5:
            delitem Plushroom, 87;
            getitem PlushroomBox, 1;
            break;
        default:
            getitem EmptyBox, 1;
    }
    closedialog;
    close;
}