Damage rebound skills.

Results 1 to 25 of 25
  1. #1
    Flow even is offline
    MemberRank
    Nov 2012 Join Date
    BaniLocation
    610Posts

    Damage rebound skills.

    I am confused with skills like Teleport Mastery, Power Guard, and Body Pressure. Any of you know in what Method do they go in, and a hint(if you want) on how to make them work as they are suppose to? I am working on a v117 server (FuckMs). I just really want to get them working again :O.
    Last edited by even; 03-02-13 at 08:02 AM.


  2. #2
    top hat Bizarre is offline
    MemberRank
    Aug 2012 Join Date
    somewhereLocation
    294Posts

    Re: Damage rebound skills.

    Well, I was looking into it.

    The entire packet structure has changed. I've messed around with the opcodes and nothing has come up.

    So good luck trying to find out. I'll post here if I find it, because this would be something that I'd actually release.

  3. #3
    Gamma Xerixe is offline
    MemberRank
    Apr 2008 Join Date
    MalaysiaLocation
    3,605Posts

    Re: Damage rebound skills.

    Last I checked in MapleSEA, it was PASSIVE_ENERGY.
    In FuckMS, it's currently handled by closedRangedAttack.

    And no, I doubt the packet structure has changed.
    Why is it so hard to sniff the packets that the client send to the server when you damage with teleport mastery / etc.
    These type of "packet fixes" are the easiest. It's harder to find out the packet that the server sends to the client.

  4. #4
    Flow even is offline
    MemberRank
    Nov 2012 Join Date
    BaniLocation
    610Posts

    Re: Damage rebound skills.

    Quote Originally Posted by Xerixe View Post
    Last I checked in MapleSEA, it was PASSIVE_ENERGY.
    In FuckMS, it's currently handled by closedRangedAttack.

    And no, I doubt the packet structure has changed.
    Why is it so hard to sniff the packets that the client send to the server when you damage with teleport mastery / etc.
    These type of "packet fixes" are the easiest. It's harder to find out the packet that the server sends to the client.
    You mean closeRangeAttack? I do not see anything related to any of those skills. Also, what do you mean by "packet fix"? Do you mean this?
    Code:
        if((ret.skill == Priest.TELEPORT_MASTERY) || (ret.skill == FPMage.TELEPORT_MASTERY) || (ret.skill == ILMage.TELEPORT_MASTERY) || (ret.skill == BattleMage.TELEPORT_MASTERY)
          || (ret.skill == Evan.TELEPORT_MASTERY) || (ret.skill == BlazeWizard.TELEPORT_MASTERY) || (ret.skill == Aran.BODY_PRESSURE) || (ret.skill == Page.POWER_GUARD) || (ret.skill == Fighter.POWER_GUARD)){
              lea.skip(4);
         }
    Edit: I found PASSIVE_ENERGY. could it be that the Recvops are wrong?

  5. #5
    Gamma Xerixe is offline
    MemberRank
    Apr 2008 Join Date
    MalaysiaLocation
    3,605Posts

    Re: Damage rebound skills.

    Who says that it has to list out the skills / have anything to do with specific skills to use the handler.
    Check MapleServerHandler to see what's handling PASSIVE_ENERGY.
    Just drop a message for the player every time that packet is sent. Then you'll know whether or not the RecvOps are right.

    I mean anything related to receiving packets. Are easy to fix. For example : The headers in RecvOps.

  6. #6
    Flow even is offline
    MemberRank
    Nov 2012 Join Date
    BaniLocation
    610Posts

    Re: Damage rebound skills.

    Nothing is handling PASSIVE_ENERGY, So I guess I have to do that. Ill try it out and let you know. Thanks for the help.

  7. #7
    Gamma Xerixe is offline
    MemberRank
    Apr 2008 Join Date
    MalaysiaLocation
    3,605Posts

    Re: Damage rebound skills.

    MapleServerHandler.java
    Code:
    case PASSIVE_ENERGY:
                    PlayerHandler.closeRangeAttack(slea, c, c.getPlayer(), true);
                    break;
    How is that nothing. Lol.

  8. #8
    Flow even is offline
    MemberRank
    Nov 2012 Join Date
    BaniLocation
    610Posts

    Re: Damage rebound skills.

    Quote Originally Posted by Xerixe View Post
    MapleServerHandler.java
    Code:
    case PASSIVE_ENERGY:
                    PlayerHandler.closeRangeAttack(slea, c, c.getPlayer(), true);
                    break;
    How is that nothing. Lol.
    It was commented for me lol.

  9. #9
    top hat Bizarre is offline
    MemberRank
    Aug 2012 Join Date
    somewhereLocation
    294Posts

    Re: Damage rebound skills.

    I've messed with the opcodes and I haven't figured it out. I've tried +1/-1. +2/-2. So on and so forth.

    PASSIVE_ENERGY in MapleServerHandler is just a case that can be accessed by the server and is basically the same as shown in the recvops.

    As far as adding a check, I'll try that out later.

  10. #10
    Gamma Xerixe is offline
    MemberRank
    Apr 2008 Join Date
    MalaysiaLocation
    3,605Posts

    Re: Damage rebound skills.

    Quote Originally Posted by Questions View Post
    I've messed with the opcodes and I haven't figured it out. I've tried +1/-1. +2/-2. So on and so forth.

    PASSIVE_ENERGY in MapleServerHandler is just a case that can be accessed by the server and is basically the same as shown in the recvops.

    As far as adding a check, I'll try that out later.
    Why would you bother testing it one by one when you can just log what packets the client are sending to the server.

  11. #11
    Flow even is offline
    MemberRank
    Nov 2012 Join Date
    BaniLocation
    610Posts

    Re: Damage rebound skills.

    The real problem was in parseDmgM, someone helped me out. But thanks for all your help guys.

  12. #12
    Proficient Member funnylord is offline
    MemberRank
    Apr 2010 Join Date
    190Posts

    Re: Damage rebound skills.

    How did u end up fixing Power reflection / etc...?

  13. #13
    Proficient Member funnylord is offline
    MemberRank
    Apr 2010 Join Date
    190Posts

    Re: Damage rebound skills.

    Ive tried fiddling around with Magic_attack

    I did +1 and tp mastery (and twister spin) began working, but magic skills no longer registered (dmg showed, not applied).

    As for poewrguard and reflection, I just tested by changing it to be Body pressure buff, followed the tree, and then made powerguard do the same

    Took a Long shot and changed Passive_Energy from Closerangeattack to MagicDamage.

    When logging tp mastery, It poppuped as magic dmg all the time, and passive energry was not being called
    Last edited by funnylord; 21-02-13 at 04:45 PM.

  14. #14
    top hat Bizarre is offline
    MemberRank
    Aug 2012 Join Date
    somewhereLocation
    294Posts

    Re: Damage rebound skills.

    You need to add some stuff to parseDmgM

  15. #15
    Proficient Member funnylord is offline
    MemberRank
    Apr 2010 Join Date
    190Posts

    Re: Damage rebound skills.

    if its IF (ret.skill == skill id || ...etc {
    lea.skip(4)
    else
    lea.skip(8)

    I had that - I changed it so the passive_energy worked along side it, as it was handled through that- - am i missing something else from parsedmgM ?

  16. #16
    top hat Bizarre is offline
    MemberRank
    Aug 2012 Join Date
    somewhereLocation
    294Posts

    Re: Damage rebound skills.

    Quote Originally Posted by funnylord View Post
    if its IF (ret.skill == skill id || ...etc {
    lea.skip(4)
    else
    lea.skip(8)

    I had that - I changed it so the passive_energy worked along side it, as it was handled through that- - am i missing something else from parsedmgM ?
    You shouldn't have messed with passive_energy at all.

    You just need to add some lines under the switch regarding the case ID's for the skills that do body damage.

  17. #17
    Proficient Member funnylord is offline
    MemberRank
    Apr 2010 Join Date
    190Posts

    Re: Damage rebound skills.

    What i did was

    Change :
    Code:
    case PASSIVE_ENERGY:
                    PlayerHandler.closeRangeAttack(slea, c, c.getPlayer(), true);
                    break;
    to
    Code:
     case PASSIVE_ENERGY:
                    PlayerHandler.MagicDamage(slea, c, c.getPlayer());
                    break;
    AFter that It worked flawlessly . - Out of every skill i tried, Passive_energy wasnt being logged.

    Before the Change, if i did Magic_attack + 1 - they worked, but other magic skills didnt.
    Doing this i could change Passive_energy to 82 , and leave Magic Attack at 80/81(cant rmbr)

    My Reasoning Behind this, was when i did Magic_Attack + 1 , Teleport Mastery Logged as Magic Damage, So i thought to change whatever handled it to magic damage as well.

    As for PoweGuard I was fiddling around, and just changed it to Body_pressure:

    Code:
    case 1101007: // pguard
                    case 1201007:
                        ret.statups.put(MapleBuffStat.BODY_PRESSURE, ret.info.get(MapleStatInfo.x));
                        break;
    - lazy fix imo, ill actually fix this at some point.

    You Said to Add in the Skill Id's after the switch in ParseDmgM ? I have done that, i tried 3 different spots, and coudnt get it right.

    ParseDMGM:

    Code:
    public static final AttackInfo parseDmgM(LittleEndianAccessor lea, MapleCharacter chr)
    /*      */   {
    /* 1066 */     AttackInfo ret = new AttackInfo();
    /* 1067 */     lea.skip(1);
    /* 1068 */     ret.tbyte = lea.readByte();
    /*      */ 
    /* 1070 */     ret.targets = (byte)(ret.tbyte >>> 4 & 0xF);
    /* 1071 */     ret.hits = (byte)(ret.tbyte & 0xF);
    /* 1072 */     ret.skill = lea.readInt();
    /* 1073 */     if (ret.skill >= 91000000) {
    /* 1074 */       return null;
    /*      */     }
    /* 1076 */     lea.skip(9);
      switch (ret.skill) {
                case 24121000:// mille
               // case 24121005://tempest
                //case 5101004: // Corkscrew
                //case 15101003: // Cygnus corkscrew
    
                case 5201002: // Gernard
                case 14111006: // Poison bomb
                case 4341002:
                case 4341003:
                case 5301001:
                case 5300007:
                case 31001000: // grim scythe
                case 31101000: // soul eater
                case 31111005: // carrion breath
     
    
                    ret.charge = lea.readInt();
                    break;
                default:
                    ret.charge = 0;
                    break;
            }
    /*      */ 
    /* 1096 */     ret.unk = lea.readByte();
    /* 1097 */     ret.display = lea.readUShort();
    /* 1098 */     lea.skip(4);
    /* 1099 */     lea.skip(1);
    /* 1100 */     if ((ret.skill == 5300007) || (ret.skill == 5101012) || (ret.skill == 5081001) || (ret.skill == 15101010)) {
    /* 1101 */       lea.readInt();
    /*      */     }
                  
                   if(ret.skill == 24121005){
                     lea.readInt();
                   }
    /* 1103 */     ret.speed = lea.readByte();
    /* 1104 */     ret.lastAttackTickCount = lea.readInt();
                     if ((ret.skill == 12111007) ||(ret.skill == 22161005) ||(ret.skill == 32111010) ||(ret.skill == 2111007) || (ret.skill == 2211007) || (ret.skill == 2311007)) 
                     lea.skip(4);
                 else
    /* 1105 */     lea.skip(8);
    /*      */ 
    /* 1107 */     ret.allDamage = new ArrayList();
    /*      */ 
    /* 1109 */     if (ret.skill == 4211006) {
    /* 1110 */       return parseMesoExplosion(lea, ret, chr);
    /*      */     }
    /*      */    
                 
    /* 1114 */     /*if (ret.skill == 24121000) {
    /* 1115 */      // lea.readInt();
    /*      */    // }
    /* 1117 */     for (int i = 0; i < ret.targets; i++) {
    /* 1118 */       int oid = lea.readInt();
    /*      */ 
    /* 1125 */       lea.skip(18);
    /*      */ 
    /* 1127 */       List allDamageNumbers = new ArrayList();
    /*      */ 
    /* 1129 */       for (int j = 0; j < ret.hits; j++) {
    /* 1130 */         int damage = lea.readInt();
    /*      */ 
    /* 1132 */         allDamageNumbers.add(new Pair(Integer.valueOf(damage), Boolean.valueOf(false)));
    /*      */       }
    /* 1134 */       lea.skip(4);
    /* 1135 */       ret.allDamage.add(new AttackPair(Integer.valueOf(oid).intValue(), allDamageNumbers));
    /*      */     }
    /* 1137 */     ret.position = lea.readPos();
    /* 1138 */     return ret;
    /*      */   }

  18. #18
    Apprentice Nether is offline
    MemberRank
    Sep 2012 Join Date
    10Posts

    Re: Damage rebound skills.

    you may want to take a look at your missing brackets, it will surely bring it all together.

  19. #19
    Proficient Member funnylord is offline
    MemberRank
    Apr 2010 Join Date
    190Posts

    Re: Damage rebound skills.

    XD, i think i see it, testing it now, will report. - I feel soo dumb

  20. #20
    Proficient Member funnylord is offline
    MemberRank
    Apr 2010 Join Date
    190Posts

    Re: Damage rebound skills.

    Trying to Fix Power Guard properly, - I assume it was the same way as the TP mastery fix - the number shows, but dmg still is not applied. Is it not lea.skip(4)?

  21. #21
    top hat Bizarre is offline
    MemberRank
    Aug 2012 Join Date
    somewhereLocation
    294Posts

    Re: Damage rebound skills.

    If you can. Just revert all the changes you've made to that java file and put it back to the way it was.

    Find this in DamageParse.java

    Code:
    /* 1076 */     lea.skip(9);
      switch (ret.skill) {
    Add this under it.

    Code:
     case 11101007: // Power Reflection
          case 11101006: // Dawn Warrior - Power Reflection
          case 21101003: // body pressure
           case 2111007:// tele mastery skills
                case 2211007:
                case 12111007:
                case 22161005:
                case 32111010:    
                case 2311007: // bishop tele mastery
                    lea.skip(1); // charge = 0
                    ret.charge = 0;
                    ret.display = lea.readUShort();
                    lea.skip(4);// dunno
                    ret.speed = (byte)lea.readShort();
                    ret.lastAttackTickCount = lea.readInt();
                    lea.skip(4);// looks like zeroes
                    ret.allDamage = new ArrayList();
                    for (int i = 0; i < ret.targets; i++) {
                        int oid = lea.readInt();
                        lea.skip(18);
                        List allDamageNumbers = new ArrayList();
                            for (int j = 0; j < ret.hits; j++) {
                                int damage = lea.readInt();
                                allDamageNumbers.add(new Pair(Integer.valueOf(damage), Boolean.valueOf(false)));
                            }
                        lea.skip(4);
                        ret.allDamage.add(new AttackPair(Integer.valueOf(oid).intValue(), allDamageNumbers));
                    }
                    ret.position = lea.readPos();
                    return ret;
    Make sure you revert all the past changes you've made. (I hope you kept a backup of the old code). This will fix all damage rebound skills including teleport mastery, power reflection, Aran's Body Pressure. ETC.

  22. #22
    Proficient Member funnylord is offline
    MemberRank
    Apr 2010 Join Date
    190Posts

    Re: Damage rebound skills.

    Thanks Stewie .


    What about this part :

    Code:
    case 24121000:// mille
               // case 24121005://tempest
                //case 5101004: // Corkscrew
                //case 15101003: // Cygnus corkscrew
    
                case 5201002: // Gernard
                case 14111006: // Poison bomb
                case 4341002:
                case 4341003:
                case 5301001:
                case 5300007:
                case 31001000: // grim scythe
                case 31101000: // soul eater
                case 31111005: // carrion breath
     
    
                    ret.charge = lea.readInt();
                    break;
                default:
                    ret.charge = 0;
                    break;
            }
    /*      */ 
    /* 1096 */     ret.unk = lea.readByte();
    /* 1097 */     ret.display = lea.readUShort();
    /* 1098 */     lea.skip(4);
    /* 1099 */     lea.skip(1);
    /* 1100 */     if ((ret.skill == 5300007) || (ret.skill == 5101012) || (ret.skill == 5081001) || (ret.skill == 15101010)) {
    /* 1101 */       lea.readInt();
    /*      */     }
                  
                   if(ret.skill == 24121005){
                     lea.readInt();
                   }
    This is basicaly what im replacing over before ret.speed = lea.readbyte();

    Whats the difference between the two, if you dont mind explaining.

  23. #23
    top hat Bizarre is offline
    MemberRank
    Aug 2012 Join Date
    somewhereLocation
    294Posts

    Re: Damage rebound skills.

    Quote Originally Posted by funnylord View Post
    Thanks Stewie .


    What about this part :

    Code:
    case 24121000:// mille
               // case 24121005://tempest
                //case 5101004: // Corkscrew
                //case 15101003: // Cygnus corkscrew
    
                case 5201002: // Gernard
                case 14111006: // Poison bomb
                case 4341002:
                case 4341003:
                case 5301001:
                case 5300007:
                case 31001000: // grim scythe
                case 31101000: // soul eater
                case 31111005: // carrion breath
     
    
                    ret.charge = lea.readInt();
                    break;
                default:
                    ret.charge = 0;
                    break;
            }
    /*      */ 
    /* 1096 */     ret.unk = lea.readByte();
    /* 1097 */     ret.display = lea.readUShort();
    /* 1098 */     lea.skip(4);
    /* 1099 */     lea.skip(1);
    /* 1100 */     if ((ret.skill == 5300007) || (ret.skill == 5101012) || (ret.skill == 5081001) || (ret.skill == 15101010)) {
    /* 1101 */       lea.readInt();
    /*      */     }
                  
                   if(ret.skill == 24121005){
                     lea.readInt();
                   }
    This is basicaly what im replacing over before ret.speed = lea.readbyte();

    Whats the difference between the two, if you dont mind explaining.
    What do you mean what's the difference? Just revert all the changes you've made and put the code I gave you.

    There is no taking away original code. Just adding on to it.

    The difference is that yours doesn't work like it's supposed to. Mine does. lol.

  24. #24
    Proficient Member funnylord is offline
    MemberRank
    Apr 2010 Join Date
    190Posts

    Re: Damage rebound skills.

    Idk, It just looks wierd, _ highlighted some overlaps

    Code:
    public static final AttackInfo parseDmgM(LittleEndianAccessor lea, MapleCharacter chr)
    /*      */   {
    /* 1066 */     AttackInfo ret = new AttackInfo();
    /* 1067 */     lea.skip(1);
    /* 1068 */     ret.tbyte = lea.readByte();
    /*      */ 
    /* 1070 */     ret.targets = (byte)(ret.tbyte >>> 4 & 0xF);
    /* 1071 */     ret.hits = (byte)(ret.tbyte & 0xF);
    /* 1072 */     ret.skill = lea.readInt();
    /* 1073 */     if (ret.skill >= 91000000) {
    /* 1074 */       return null;
    /*      */     }
    /* 1076 */     lea.skip(9);
      switch (ret.skill) {
    case 11101007: // Power Reflection
          case 11101006: // Dawn Warrior - Power Reflection
          case 21101003: // body pressure
           case 2111007:// tele mastery skills
                case 2211007:
                case 12111007:
                case 22161005:
                case 32111010:    
                case 2311007: // bishop tele mastery
                    lea.skip(1); // charge = 0
                    ret.charge = 0;
                    ret.display = lea.readUShort();
                    lea.skip(4);// dunno
                    ret.speed = (byte)lea.readShort();
                    ret.lastAttackTickCount = lea.readInt();
                    lea.skip(4);// looks like zeroes
                    ret.allDamage = new ArrayList();
                    for (int i = 0; i < ret.targets; i++) {
                        int oid = lea.readInt();
                        lea.skip(18);
                        List allDamageNumbers = new ArrayList();
                            for (int j = 0; j < ret.hits; j++) {
                                int damage = lea.readInt();
                                allDamageNumbers.add(new Pair(Integer.valueOf(damage), Boolean.valueOf(false)));
                            }
                        lea.skip(4);
                        ret.allDamage.add(new AttackPair(Integer.valueOf(oid).intValue(), allDamageNumbers));
                    }
                    ret.position = lea.readPos();
                    return ret;
                case 24121000:// mille
               // case 24121005://tempest
                //case 5101004: // Corkscrew
                //case 15101003: // Cygnus corkscrew
    
                case 5201002: // Gernard
                case 14111006: // Poison bomb
                case 4341002:
                case 4341003:
                case 5301001:
                case 5300007:
                case 31001000: // grim scythe
                case 31101000: // soul eater
                case 31111005: // carrion breath
     
    
                    ret.charge = lea.readInt();
                    break;
                default:
                    ret.charge = 0;
                    break;
            }
    /*      */ 
    /* 1096 */     ret.unk = lea.readByte();
    /* 1097 */     ret.display = lea.readUShort();
    /* 1098 */     lea.skip(4);
    /* 1099 */     lea.skip(1);
    /* 1100 */     if ((ret.skill == 5300007) || (ret.skill == 5101012) || (ret.skill == 5081001) || (ret.skill == 15101010)) {
    /* 1101 */       lea.readInt();
    /*      */     }
                  
                   if(ret.skill == 24121005){
                     lea.readInt();
                   }
    /* 1103 */     ret.speed = lea.readByte();
    /* 1104 */     ret.lastAttackTickCount = lea.readInt();
                     if ((ret.skill == 12111007) ||(ret.skill == 22161005) ||(ret.skill == 32111010) ||(ret.skill == 2111007) || (ret.skill == 2211007) || (ret.skill == 2311007)) 
                     lea.skip(4);
                 else
    /* 1105 */     lea.skip(8);
    /*      */ 
    /* 1107 */     ret.allDamage = new ArrayList();
    /*      */ 
    /* 1109 */     if (ret.skill == 4211006) {
    /* 1110 */       return parseMesoExplosion(lea, ret, chr);
    /*      */     }
    /*      */    
                 
    /* 1114 */     /*if (ret.skill == 24121000) {
    /* 1115 */      // lea.readInt();
    /*      */    // }
    /* 1117 */     for (int i = 0; i < ret.targets; i++) {
    /* 1118 */       int oid = lea.readInt();
    /*      */ 
    /* 1125 */       lea.skip(18);
    /*      */ 
    /* 1127 */       List allDamageNumbers = new ArrayList();
    /*      */ 
    /* 1129 */       for (int j = 0; j < ret.hits; j++) {
    /* 1130 */         int damage = lea.readInt();
    /*      */ 
    /* 1132 */         allDamageNumbers.add(new Pair(Integer.valueOf(damage), Boolean.valueOf(false)));
    /*      */       }
    /* 1134 */       lea.skip(4);
    /* 1135 */       ret.allDamage.add(new AttackPair(Integer.valueOf(oid).intValue(), allDamageNumbers));
    /*      */     }
    /* 1137 */     ret.position = lea.readPos();
    /* 1138 */     return ret;
    /*      */   }

  25. #25
    Account Upgraded | Title Enabled! edwinkbs is offline
    MemberRank
    Apr 2009 Join Date
    MalaysiaLocation
    831Posts

    Re: Damage rebound skills.

    You all should actually print out the packet and read it one by one
    public static final AttackInfo parseDmgM(LittleEndianAccessor lea, MapleCharacter chr)
    /* */ {
    System.out.println("Parsedmgm: " + lea.toString());



Advertisement