Thread: 1v1 Bug :S

Results 1 to 6 of 6
  1. #1 1v1 Bug :S 
    Software
    Guest
    Dear rune-server members,

    My server has 50% pvp and i want to make it better, it has one really stupid bug, When player attacks other player the player ho Gets attacked if he doesnt do anything like attack back, others can attack him too.

    If it's needed heres 1v1 code from case 73:
    Code:
                    if (AttackingOn2.attackingPlayerId != playerId
                            && AttackingOn2.attackingPlayerId != 0) {
                        sendMessage("That player is already in combat.");
                        attackingPlayerId = 0;
                        ResetAttack();
                        break;
                    }
    Reply With Quote  
     

  2. #2  
    Community Veteran

    Cascade's Avatar
    Join Date
    Oct 2006
    Posts
    1,022
    Thanks given
    12
    Thanks received
    27
    Rep Power
    912
    Thats because if the player isn't attacking anybody and is being attacked case 73 still isn't called. You would have to find a way around it.
    Reply With Quote  
     

  3. #3  
    Software
    Guest
    i dunno how, im asking for help
    Reply With Quote  
     

  4. #4  
    Ex-Administrator

    Join Date
    Jul 2006
    Age
    31
    Posts
    507
    Thanks given
    6
    Thanks received
    17
    Rep Power
    75
    Or you can just make the client that is attacking set a variable on the client he is attacking.
    Reply With Quote  
     

  5. #5  
    Human

    Only's Avatar
    Join Date
    Aug 2008
    Posts
    1,108
    Thanks given
    1
    Thanks received
    18
    Rep Power
    116
    Search for the method - ResetAttack, if this is with an uppercase R then your case isn't called, other way... if your method is "resetAttack" with a lowercase 'r' then you gotta make it resetAttack(); in your if statement.
    Reply With Quote  
     

  6. #6  
    Software
    Guest
    Quote Originally Posted by Only View Post
    Search for the method - ResetAttack, if this is with an uppercase R then your case isn't called, other way... if your method is "resetAttack" with a lowercase 'r' then you gotta make it resetAttack(); in your if statement.
    Listen. The player ho is attacking others CAN'T attack him but they can attack the other ho GETS attacked if he doesnt attack back.
    Reply With Quote  
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •