Jump to content

Pacman360

Members
  • Posts

    30
  • Joined

  • Last visited

Posts posted by Pacman360

  1. 56 minutes ago, M45T3R said:

    Try looking in the script_commands.txt file in the docs folder

    
    *callshop "<name>",<option>;
    
    These are a series of commands used to create dynamic shops.
    The 'callshop' function calls an invisible shop (view -1) as if the player clicked on it.
    
    The options are:
        0 = The normal window (buy, sell and cancel)
        1 = The buy window
        2 = The sell window

     

    Thank you! Solved this case. regards. xx

  2. Hello! How can I make this first option trigger selling window rather than buy? Thanks in Advance.

    crystilia,72,88,3    script    Tool Dealer#prt    125,{
        mes "What do you like to buy?";
        switch( select( "Sell", "Ammunition Box", "Single Ammo", "Identify My Items", "Nothing" ) ) {
        next;
        case 1:
            callshop "Sell",1;
            end;
    
        case 2:
            callshop "AmmunitionBox",1;
            end;
        case 3:
            callshop "SingleAmmo",1;
            end;
        case 4:
            mes "Here you go";
            callfunc "identify123";
            end;
        case 5:
            mes "Okay, have a nice day";
            close;
            
        }
    }
    -    shop    Sell#shop::Sell    -1,501:-1
    -    shop    Tool Dealer#shop::AmmunitionBox    -1,501:-1 // Add ammo box here
    -    shop    Tool Dealer#shop::SingleAmmo    -1,502:-1 //single ammo add here
    
    function    script    identify123    {
            getinventorylist;
                while( .@idn < @inventorylist_count ){
                    if ( !@inventorylist_identify[.@idn] ){
                        delitem2 @inventorylist_id[.@idn],1,0,0,0,0,0,0,0;
                        getitem @inventorylist_id[.@idn],1;
                    }
                    .@idn++;
                }
    close;
    }

     

  3. 6 minutes ago, Haruka Mayumi said:

    It's not recommended to stop a firewall. this will cause you a lot of problems.. and one of the problem is vulnerability on most of the DDoS Tools..
    It is much better to only allow the BlueHost IP to connect on your Server.. to do so.. you need to use this command for firewalld

    firewall-cmd --add-rich-rule 'rule family="ipv4" source address="YOUR_BLUEHOST_IP" service name="mysql" accept' --permanent

    dont forget to reload the firewall rule to take effect by simply using this command

    firewall-cmd --reload

    once done. make sure your firewalld is enabled..

    Wow this worked well!

     

    Thank you very much! amazing

  4. 26 minutes ago, Haruka Mayumi said:

    This error means that your bluehost vps cannot reach the target server. the cause might be

    - IP is not configured correctly ( see config/servers.php )
    - The target server might be offline or down
    - A firewall is blocking remote connections ( most of the time )

    If you see that IP is configured correctly and you can connect to your target server via SSH. then it's most likely firewall that is blocking it such as iptables...
    to see your iptables rules. simply use the command - iptables -S
    if you see that it is allowed on ip tables, then most likely you are using another firewall as default such as ufw or firewalld. you just need to allow the ports connection remotely

     

    Thank you very much for the response, i did systemctl stop firewalld ( centos8 ) and it worked. 

     

    I am wondering what do i type to stop firewall just for the website rather than overall stoppage? thanks

  5.  

    Hello everyone, i am asking for help on this one. I think i have figured correctly but this one keeps popping up upon flux cp installation.

    i have hosted my vps in: vultr.com 

    i have hosted my webhost in bluehost.com

     

    what can be the problem? thanks

    04DWLvj.png 

  6. Can anyone help me with this script out? It's working fine. but the problem is even if the dual is not inside the map it's still getting kick. Like if client 1 = goes inside restricted map. client 2= gets kicked even AFKing in maintown and not in a same map with client 1.

     

    Here's the script:

     

    - script duald -,{

     
    OnPCLoadMapEvent:
            set .@name$, strcharinfo(0);
            set .@map$,strcharinfo(3);
            if (query_sql("SELECT `char`.`name` FROM `char` LEFT JOIN login ON `char`.account_id=login.account_id WHERE login.last_mac=(SELECT last_mac FROM login WHERE account_id="+getcharid(3)+") AND `char`.online=1 AND `char`.char_id!="+getcharid(0), .@name$) >= 1) {
                    for (set .@i,0; .@i<getarraysize(.@name$); set .@i,.@i+1) {
                            if ( ( .@map$=="schg_cas07" || .@map$=="schg_cas08" || .@map$=="arug_cas06" || .@map$=="arug_cas07" || .@map$=="arug_cas08" || .@map$=="rush_cas01" || .@map$=="rush_cas02" || .@map$=="rush_cas03" || .@map$=="rush_cas04" || .@map$=="bat_b03" ) )
                                    set .@samemac, .@samemac +1;
                    }
                    if (.@samemac >= 1) {
                            announce "Sorry, only 1 account per computer can be logged in at a time on this map.", bc_self;
                             atcommand "@kick " + .@name$;
                    }
            }
            end;
    }
  7. This script is all working except 1 thing: Monster card level doesn't work. I tried to put it up to 25 but when I try to trade-in level 50 and above card monster it just says "Card is under the minimum level".

     

     

    //===== rAthena Script =======================================
    //= Card Trader
    //===== By: ==================================================
    //= Euphy
    //===== Current Version: =====================================
    //= 1.1
    //===== Compatible With: =====================================
    //= rAthena SVN
    //===== Description: =========================================
    //= Exchange cards for points.
    //============================================================

    prontera,165,196,6    script    Card Trader    90,{
        mes "[Card Trader]";
        mes "Hi, "+strcharinfo(0)+"!";
        mes "What can I do for you?";
        next;
        switch(select(" > Information: > Trade in cards: > Point shop (^0055FF"+getd(.Points$)+"^000000): > Leave")) {
        case 1:
            mes "[Card Trader]";
            mes "Do you find that you've got";
            mes "useless cards lying around?";
            mes "I'll be glad to take them off";
            mes "your hands!";
            next;
            mes "[Card Trader]";
            mes "I'll give you ^0055FF"+.Points[0]+" Point"+((.Points[0] == 1)?"":"s")+"^000000 for each";
            mes "card you give me, and";
            mes "^0055FF"+.Points[1]+" Points^000000 for MVP cards.";
            mes "You can trade those points";
            mes "for items later on.";
            mes "How does that sound?";
            emotion e_cash;
            close;
        case 2:
            mes "[Card Trader]";
            mes "Select the cards you";
            mes "want to trade in.";
            if (.Level) {
                mes " ";
                mes "They must be dropped";
                mes "by monsters of level";
                mes .Level+" and above.";
            }
            deletearray @sold_nameid[0],getarraysize(@sold_nameid);
            callshop "card_shop",2;
            npcshopattach "card_shop";
            end;
        case 3:
            mes "[Card Trader]";
            mes "You have ^0055FF"+getd(.Points$)+"^000000 Point"+((getd(.Points$) == 1)?".":"s.");
            callshop "card_shop",1;
            npcshopattach "card_shop";
            end;
        case 4:
            mes "[Card Trader]";
            mes "*yawn*";
            mes "See you later!";
            emotion e_yawn;
            close;        
        }

    OnSellItem:
        mes "Cards to sell:";
        mes "-----------------------------------";
        for(set .@i,0; .@i<getarraysize(@sold_nameid); set .@i,.@i+1)
            if (@sold_nameid[.@i] > 4000 && @sold_nameid[.@i] < 4700) {
                if (.Level) {
                    query_sql("SELECT `LV` FROM `mob_db` WHERE `DropCardid` = "+@sold_nameid[.@i],.@lv);
                    if (.@lv < .Level) {
                        dispbottom getitemname(@sold_nameid[.@i])+" is under the minimum level.";
                        continue;
                    }
                }
                set .@card_id[getarraysize(.@card_id)], @sold_nameid[.@i];
                set .@card_amt[getarraysize(.@card_amt)], @sold_quantity[.@i];
                set .@mvp, compare(.MVP$,""+@sold_nameid[.@i]);
                mes ((.@mvp)?"  ^FF0000":"  ^777777")+@sold_quantity[.@i]+"x "+getitemname(@sold_nameid[.@i])+"^000000";
                set .@card_total, .@card_total+(@sold_quantity[.@i]*((.@mvp)?.Points[1]:.Points[0]));
            }
        deletearray @sold_nameid[0], getarraysize(@sold_nameid);
        deletearray @sold_quantity[0], getarraysize(@sold_quantity);
        if (!.@card_id) {
            mes "  ^777777(none)^000000";
            emotion e_swt;
            close;
        }
        mes " ";
        mes "---------- Total: ^0055FF"+.@card_total+" pt.^000000 -------";
        next;
        if(select(" > ^0055FFComplete trade...^000000: > ^777777Cancel^000000") == 2) {
            mes "[Card Trader]";
            mes "Oh, okay...";
            emotion e_hmm;
            close;
        }
        for(set .@i,0; .@i<getarraysize(.@card_id); set .@i,.@i+1)
            delitem .@card_id[.@i],.@card_amt[.@i];
        setd .Points$, getd(.Points$)+.@card_total;
        mes "[Card Trader]";
        mes "All done!";
        emotion e_ho;
        close;

    OnBuyItem:
        for(set .@i,0; .@i<getarraysize(@bought_nameid); set .@i,.@i+1)
            for(set .@j,0; .@j<getarraysize(.Shop); set .@j,.@j+2)
                if (@bought_nameid[.@i] == .Shop[.@j]) {
                    set .@cost, .@cost+(.Shop[.@j+1]*@bought_quantity[.@i]);
                    break;
                }
        if (.@cost > getd(.Points$)) {
            mes "[Card Trader]";
            mes "You don't have enough Points.";
            emotion e_omg;
        }
        else {
            mes "Items purchased:";
            mes "-----------------------------------";
            for(set .@i,0; .@i<getarraysize(@bought_nameid); set .@i,.@i+1) {
                getitem @bought_nameid[.@i], @bought_quantity[.@i];
                mes "  ^777777"+@bought_quantity[.@i]+"x "+getitemname(@bought_nameid[.@i])+"^000000";
            }
            mes " ";
            mes "---------- Total: ^0055FF"+.@cost+" pt.^000000 -------";
            setd .Points$, getd(.Points$)-.@cost;
            emotion e_cash;
        }
        deletearray @bought_nameid[0], getarraysize(@bought_nameid);
        deletearray @bought_quantity[0], getarraysize(@bought_quantity);
        close;

    OnInit:
        set .Level,25;           // Minimum monster level to trade corresponding cards.
        set .Points$,"#Card_Points";    // Variable to store points.
        setarray .Shop[0],        // Card Shop items: <ID>,<point cost>
          616,15;
        setarray .Points[0],1,5;    // Points per <normal card>,<MVP card>
        set .MVP$,            // List of MVP cards.
          "4121,4123,4128,4131,4132,4134,4135,4137,4142,4143,4144,4145,4146,4147,4148,4168,4236,"+
          "4241,4263,4276,4302,4305,4318,4324,4330,4342,4357,4359,4361,4363,4365,4399,4403,4407";
        
        npcshopdelitem "card_shop",909;
        for(set .@i,0; .@i<getarraysize(.Shop); set .@i,.@i+2)
            npcshopadditem "card_shop",.Shop[.@i],.Shop[.@i+1];
        end;
    }
    -    shop    card_shop    -1,909:-1

     

  8. Hello Rathena!! I would like to request to modify this npc.

     

    This NPC is a working reward giver bIut it's not working as I want.

    It gives the guild leader castle owner a reward then they win a castle but when a separate war of emperium ends It enables them to receive the reward aswell.

     

    So basically I just want to block receiving the reward when they have already received the reward from their castle even tho another WoE  starts / ends.

     

    Sorry for my english.

     

    Here is my current script.

     

     

    //===== rAthena Script =======================================
    //= Guild Prize Giveaway
    //===== By: ==================================================
    //= AnnieRuru / Mysterious
    //===== Current Version: =====================================
    //= 1.5
    //===== Compatible With: =====================================
    //= rAthena SVN
    //===== Description: =========================================
    //= Rewards guild masters of castle owners after each
    //= War of Emperium session.
    //===== Additional Comments: =================================
    //= v1.0 - Intitial Re-release [Mysterious]
    //= v1.1 - Language structures [Mysterious]
    //= v1.2 - Added divisions [Mysterious]
    //= v1.3 - Added proper information [Mysterious]
    //= v1.4 - Optimized! [Euphy]
    //= v1.5 - Little bit of cleaning [Mysterious]
    //============================================================

    prontera,159,181,5    script    WoE Rewards    413,{

        mes "[Castle Rewards]";
        if (agitcheck() || agitcheck2()) { mes "WoE is currently still in progress."; close; }
        mes "Please select a castle:";
        next;
        for(set .@i,0; .@i<30; set .@i,.@i+1)
            set .@menu$, .@menu$+getcastlename(.Castles$[.@i])+":";
        set .@i, select(.@menu$)-1;
        mes "[Castle Rewards]";
        if (getcastledata(.Castles$[.@i],1) != getcharid(2)) { mes "You aren't the owner of this castle."; close; }
        if (getguildmasterid(getcharid(2)) != getcharid(0)) { mes "Only the guild master can claim the reward."; close; }
        if ($castle_claimed&(1<<.@i)) { mes "You've already claimed this castle's reward!"; close; }
        mes "Here's your reward for conquering "+getcastlename(.Castles$[.@i])+".";
        set $castle_claimed, $castle_claimed | (1<<.@i);
        getitem 7539,300;  //Set your prize here!
        close;

    OnAgitEnd:
        set $castle_claimed, 0;
        end;

    OnInit:
        setarray .Castles$[0],
            "arug_cas03","schg_cas03";
        end;
    }

     

    My SVN is eAthena

  9. Hello, how can I make a box like OBB?

    I'd like to put items in random chance for example:

    Random chance of getting:

    - Poring card

    - 10x Platinum Coin

    - 5x Gold Coin

    - Muffler

    - Boots

     

    Thanks in advance

  10. hey, i would like to request a script... i found a similar script but its buggy.

    anyway the script i want to request is mvp custom drop.

     

    i want all mvps to drop 1 item at 80% chance. lets say itemID 7771

    i found a script somewhere but its buggy because mvp slaves also drop it and mini bosses. i just want the mvp to drop it.

     

    anyone? thanks in advance

×
×
  • Create New...