[Release] Making Commands/Random Things

Page 4 of 10 FirstFirst 12345678910 LastLast
Results 46 to 60 of 138
  1. #46
    projectNano LightRyuzaki is offline
    MemberRank
    Sep 2008 Join Date
    TexasLocation
    338Posts

    Re: [Release] Making Commands/Random Things

    Hey Jay can you make !unban <charname> that unbans the character from ip ban mac ban and mac filter and for tempban.
    i need one cause my server just got screwed up and accounts got deleted and mysqls being gay and doesnt do anything for unbanning even if i truncate them.

  2. #47
    Apprentice xxInternalxx is offline
    MemberRank
    Dec 2008 Join Date
    18Posts

    Re: [Release] Making Commands/Random Things

    Axel

    Could you make cm.instance(with all variables needed) in the NPCConversationManager.java ?? :D
    Like it would do everything that is needed for an instance instead of all those checks etc etc -.-"
    Would save alot of time for many people. ^^
    Thanks for your kindness to help xD

  3. #48
    Infraction Banned MiniAxel is offline
    MemberRank
    Sep 2006 Join Date
    906Posts

    Re: [Release] Making Commands/Random Things

    Quote Originally Posted by xxInternalxx View Post
    Axel

    Could you make cm.instance(with all variables needed) in the NPCConversationManager.java ?? :D
    Like it would do everything that is needed for an instance instead of all those checks etc etc -.-"
    Would save alot of time for many people. ^^
    Thanks for your kindness to help xD
    I don't understand what you're asking for...

  4. #49
    Account Upgraded | Title Enabled! yuniordiaz is offline
    MemberRank
    May 2008 Join Date
    C: DriveLocation
    1,045Posts

    Re: [Release] Making Commands/Random Things

    Quote Originally Posted by MiniAxel View Post
    MapleCharacter.java
    Add
    Code:
    private boolean maxStatScroll = false;
    Code:
        public boolean getMaxStatScroll() {
            return maxStatScroll;
        }
        
        public void setMaxStatScroll(boolean set) {
            this.maxStatScroll = set;
        }
    in MapleItemInformationProvider

    add
    Code:
    private MapleClient c;
    Replace your
    scrollEquipWithId function with

    Code:
    public IItem scrollEquipWithId(IItem equip, int scrollId, boolean usingWhiteScroll) {
            if (equip instanceof Equip) {
                Equip nEquip = (Equip) equip;
                Map<String, Integer> stats = this.getEquipStats(scrollId);
                Map<String, Integer> eqstats = this.getEquipStats(equip.getItemId());
                            if(!c.getPlayer().getMaxStatScroll()) {
                if ((nEquip.getUpgradeSlots() > 0 || isCleanSlate(scrollId)) && Math.ceil(Math.random() * 100.0) <= stats.get("success")) {
                    switch(scrollId) {
                        case 2049000:
                        case 2049001:
                        case 2049002:
                        case 2049003:
                            if (nEquip.getLevel() + nEquip.getUpgradeSlots() < eqstats.get("tuc")) {
                                byte newSlots = (byte) (nEquip.getUpgradeSlots() + 1);
                                nEquip.setUpgradeSlots(newSlots);
                            }
                            break;
                        case 2049100:
                                            case 2049101:
                                            case 2049102:
                            int increase = 1;
                            if (Math.ceil(Math.random() * 100.0) <= 50)
                                increase = increase*-1;
                            if (nEquip.getStr() > 0) {
                                short newStat = (short)(nEquip.getStr()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setStr(newStat);
                            }
                            if (nEquip.getDex() > 0) {
                                short newStat = (short)(nEquip.getDex()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setDex(newStat);
                            }
                            if (nEquip.getInt() > 0) {
                                short newStat = (short)(nEquip.getInt()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setInt(newStat);
                            }
                            if (nEquip.getLuk() > 0) {
                                short newStat = (short)(nEquip.getLuk()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setLuk(newStat);
                            }
                            if (nEquip.getWatk() > 0) {
                                short newStat = (short)(nEquip.getWatk()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setWatk(newStat);
                            }
                            if (nEquip.getWdef() > 0) {
                                short newStat = (short)(nEquip.getWdef()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setWdef(newStat);
                            }
                            if (nEquip.getMatk() > 0) {
                                short newStat = (short)(nEquip.getMatk()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setMatk(newStat);
                            }
                            if (nEquip.getMdef() > 0) {
                                short newStat = (short)(nEquip.getMdef()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setMdef(newStat);
                            }
                            if (nEquip.getAcc() > 0) {
                                short newStat = (short)(nEquip.getAcc()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setAcc(newStat);
                            }
                            if (nEquip.getAvoid() > 0) {
                                short newStat = (short)(nEquip.getAvoid()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setAvoid(newStat);
                            }
                            if (nEquip.getSpeed() > 0) {
                                short newStat = (short)(nEquip.getSpeed()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setSpeed(newStat);
                            }
                            if (nEquip.getJump() > 0) {
                                short newStat = (short)(nEquip.getJump()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setJump(newStat);
                            }
                            if (nEquip.getHp() > 0) {
                                short newStat = (short)(nEquip.getHp()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setHp(newStat);
                            } 
                            if (nEquip.getMp() > 0) {
                                short newStat = (short)(nEquip.getMp()+Math.ceil(Math.random() * 5.0)*increase);
                                nEquip.setMp(newStat);
                            }
                            break;
                        default:
                            for (Entry<String, Integer> stat : stats.entrySet()) {
                                if (stat.getKey().equals("STR"))
                                    nEquip.setStr((short) (nEquip.getStr() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("DEX"))
                                    nEquip.setDex((short) (nEquip.getDex() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("INT"))
                                    nEquip.setInt((short) (nEquip.getInt() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("LUK"))
                                    nEquip.setLuk((short) (nEquip.getLuk() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("PAD"))
                                    nEquip.setWatk((short) (nEquip.getWatk() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("PDD"))
                                    nEquip.setWdef((short) (nEquip.getWdef() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("MAD"))
                                    nEquip.setMatk((short) (nEquip.getMatk() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("MDD"))
                                    nEquip.setMdef((short) (nEquip.getMdef() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("ACC"))
                                    nEquip.setAcc((short) (nEquip.getAcc() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("EVA"))
                                    nEquip.setAvoid((short) (nEquip.getAvoid() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("Speed"))
                                    nEquip.setSpeed((short) (nEquip.getSpeed() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("Jump"))
                                    nEquip.setJump((short) (nEquip.getJump() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("MHP"))
                                    nEquip.setHp((short) (nEquip.getHp() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("MMP"))
                                    nEquip.setMp((short) (nEquip.getMp() + stat.getValue().intValue()));
                                else if (stat.getKey().equals("afterImage")) {
                                }
                            }
                            break;
                    }
                    if (!isCleanSlate(scrollId)) {
                        nEquip.setUpgradeSlots((byte) (nEquip.getUpgradeSlots() - 1));
                        nEquip.setLevel((byte) (nEquip.getLevel() + 1));
                    }
                } else {
                    if (!usingWhiteScroll && !isCleanSlate(scrollId)) {
                        nEquip.setUpgradeSlots((byte) (nEquip.getUpgradeSlots() - 1));
                    }
                    if (Math.ceil(1.0 + Math.random() * 100.0) < stats.get("cursed")) {
                        // DESTROY :) (O.O!)
                        return null;
                    }
                }
                            } else {
                                short newStat = (short)(Short.MAX_VALUE);
                                nEquip.setStr(newStat);
                                nEquip.setInt(newStat);
                                nEquip.setLuk(newStat);
                                nEquip.setDex(newStat);
                                nEquip.setWatk(newStat);
                                nEquip.setWdef(newStat);
                                nEquip.setMatk(newStat);
                                nEquip.setMdef(newStat);
                                nEquip.setAcc(newStat);
                                nEquip.setAvoid(newStat);
                                nEquip.setSpeed(newStat);
                                nEquip.setJump(newStat);
                                
                            }
            }
            return equip;
        }
    Command :
    Code:
     else if(splitted[0].equals("!scrollmax")) {
                        if(!c.getPlayer().getMaxStatScroll()) {
                            c.getPlayer().setMaxStatScroll(true);
                            mc.dropMessage("All Scrolls will provide Max Stats");
                        } else if(c.getPlayer().getMaxStatScroll()) {
                            c.getPlayer().setMaxStatScroll(false);
                            mc.dropMessage("Scrolls will no longer provide Max Stats");
                        }
                    }
    Ok ty so the command is to turn it off on because I was only planning on using this for GM's

  5. #50
    Proficient Member tsunamishine is offline
    MemberRank
    Nov 2008 Join Date
    LaByStoryLocation
    193Posts

    Re: [Release] Making Commands/Random Things

    i have got a request, can you make super skills for v0.62? meaning skills that last for about 30 minutes? :D

  6. #51
    Account Upgraded | Title Enabled! xCheetah is offline
    MemberRank
    Jun 2008 Join Date
    332Posts

    Re: [Release] Making Commands/Random Things

    Axel, could you fix the clock command ;o

  7. #52
    Infraction Banned MrMysterious is offline
    MemberRank
    Dec 2008 Join Date
    In a treeLocation
    752Posts

    Re: [Release] Making Commands/Random Things

    What do you mean'fix' ?

  8. #53
    Infraction Banned MiniAxel is offline
    MemberRank
    Sep 2006 Join Date
    906Posts

    Re: [Release] Making Commands/Random Things

    Quote Originally Posted by tsunamishine View Post
    i have got a request, can you make super skills for v0.62? meaning skills that last for about 30 minutes? :D
    I don't edit XMLs.

  9. #54
    Proficient Member CrisTheWind is offline
    MemberRank
    Sep 2008 Join Date
    The CloudsLocation
    156Posts

    Re: [Release] Making Commands/Random Things

    Jayy;
    ohai. u shuld totally maek handlur wich maek timur apeer wun minuet bfore nuu yeers.

  10. #55
    Infraction Banned MiniAxel is offline
    MemberRank
    Sep 2006 Join Date
    906Posts

    Re: [Release] Making Commands/Random Things

    Need more ideas.

  11. #56
    Enthusiast Monkeyskill is offline
    MemberRank
    Apr 2008 Join Date
    38Posts

    Re: [Release] Making Commands/Random Things

    Can you make a shop with all scrolls and skill books please :D? Any npc

    And

    a commands that makes ppl lose hp when you type it and loses mesos when u use it please like @punch [Name]

    Edit :
    Can you help me remove 100% work scrolls when using it and gm doesnt lose slots (ThePack) v62

  12. #57
    Alpha Member Markii is offline
    MemberRank
    Nov 2008 Join Date
    NewyorkLocation
    1,917Posts

    Re: [Release] Making Commands/Random Things

    Need a command that when the Event Message Pops up the Players can just do @event and it will warp them to a Waiting Room .the Map i will pick after.

  13. #58
    Account Upgraded | Title Enabled! iamSTEVE is offline
    MemberRank
    Jul 2008 Join Date
    528Posts

    Re: [Release] Making Commands/Random Things

    Lol Jay, go fix rings. And marriage rings, then commit all PQs to Prometheus. And guest login/overriding Mapletips.

  14. #59
    Apprentice xxInternalxx is offline
    MemberRank
    Dec 2008 Join Date
    18Posts

    Re: [Release] Making Commands/Random Things

    Moogra do you have msn? If you have, could you message me it? I have a problem with a script of mine... :( And I want to keep it private xD
    Or MiniAxel is okay too :P

  15. #60
    Alpha Member Moogra is offline
    MemberRank
    Jul 2008 Join Date
    1,804Posts

    Re: [Release] Making Commands/Random Things

    Make a command called !helloworld that says Hello, World! when executed.
    ex:
    PHP Code:
    else if (splitted[0].equals("!helloworld") {
    mc.dropMessage("Hello, World!");

    I want it like this.

    Hmmm I'm going to make a command that generates commands (monster spawn)
    like !addcommand spawn 100100 10 bob346
    amkes a commadn that does !spawn 100100 10
    and it names it bob346

    edit
    PHP Code:
    else if (splitted[0].equals("!addcommand")) {
                if (!
    splitted[1].equals("spawn")) return false;
                
    int monsterId Integer.parseInt(splitted[2]);
                
    int quantity Integer.parseInt(splitted[3]);
                
    String name splitted[4];
                    try {
                        
    Connection con DatabaseConnection.getConnection();
                        
    PreparedStatement ps con.prepareStatement("INSERT INTO newcommands (monsterId, quantity, name) VALUES (?, ?, ?)");
                        
    ps.setInt(1monsterId);
                        
    ps.setInt(2quantity);
                        
    ps.setString(3name);
                        
    ps.executeUpdate();
                    } catch (
    SQLException e) {
                        
    mc.dropMessage("Something bad happened.");
                        return 
    false;
                    }
            } 
    Yay

    now help me select them when someone does !bob234 or whatever



Advertisement