Thread: Admins Killing players

Results 1 to 10 of 10
  1. #1 [Pi] Admins Killing players 
    Registered Member fourshorty's Avatar
    Join Date
    Oct 2013
    Posts
    148
    Thanks given
    17
    Thanks received
    10
    Rep Power
    11
    I was wondering if I can make it so that if a owner Rank = 3 , kills a normal player they don't lose thier items I already have it that if a normal player kills an admin the admin doesn't lose an item. I was wondering I can get the code and how to do it for if the normal player dies. Thank you I might even pay , maybe.
    Reply With Quote  
     

  2. #2  
    Registered Member fourshorty's Avatar
    Join Date
    Oct 2013
    Posts
    148
    Thanks given
    17
    Thanks received
    10
    Rep Power
    11
    please skype me @imsoskills
    Reply With Quote  
     

  3. #3  
    Chow down on these noodles
    OodlesOfNoodles's Avatar
    Join Date
    May 2011
    Posts
    1,819
    Thanks given
    235
    Thanks received
    91
    Rep Power
    55
    Just disable admins from pking?
    Reply With Quote  
     

  4. #4  
    Registered Member fourshorty's Avatar
    Join Date
    Oct 2013
    Posts
    148
    Thanks given
    17
    Thanks received
    10
    Rep Power
    11
    Quote Originally Posted by OodlesOfNoodles View Post
    Just disable admins from pking?
    No, This is for owners only ; admins can spawn. I was just wanting to do this for owners like myself so we could have events in the wild and not be killing players and making them lose items , please anyway to add this please help me.
    Reply With Quote  
     

  5. #5  
    Banned
    Join Date
    Oct 2013
    Age
    25
    Posts
    685
    Thanks given
    15
    Thanks received
    68
    Rep Power
    0
    Will, since you didn't tell me what base you are using... I decided to just make up a code and this could be easily converted.

    1) What you want to do is make a check in the combat method, for player vs player.
    Code:
    public boolean ownerAttackingPlayer;
    
    if (player.getStaffRights() == 3) {
        player.ownerAttackingPlayer = true;
    }
    2) The next thing you want to do is go to the drops method (for combat) and use that sane check as this example.
    Code:
    if (Victim.isPlayer() && player.ownerAttackingPlayer) {
              ownerAttackingPlayer = false;
              return;
    }
    You're welcome.
    Reply With Quote  
     

  6. #6  
    Registered Member fourshorty's Avatar
    Join Date
    Oct 2013
    Posts
    148
    Thanks given
    17
    Thanks received
    10
    Rep Power
    11
    Quote Originally Posted by Dri Comics View Post
    Will, since you didn't tell me what base you are using... I decided to just make up a code and this could be easily converted.

    1) What you want to do is make a check in the combat method, for player vs player.
    Code:
    public boolean ownerAttackingPlayer;
    
    if (player.getStaffRights() == 3) {
        player.ownerAttackingPlayer = true;
    }
    2) The next thing you want to do is go to the drops method (for combat) and use that sane check as this example.
    Code:
    if (Victim.isPlayer() && player.ownerAttackingPlayer) {
              ownerAttackingPlayer = false;
              return;
    }
    You're welcome.
    Thanks and its Pi , but im still unsure what to do with this code lol
    Reply With Quote  
     

  7. #7  
    Registered Member
    Join Date
    Jul 2012
    Posts
    80
    Thanks given
    0
    Thanks received
    1
    Rep Power
    11
    its in the config file, should say something like admins able to kill = "false"; change to true
    Reply With Quote  
     

  8. #8  
    Registered Member fourshorty's Avatar
    Join Date
    Oct 2013
    Posts
    148
    Thanks given
    17
    Thanks received
    10
    Rep Power
    11
    Quote Originally Posted by pigeye123 View Post
    its in the config file, should say something like admins able to kill = "false"; change to true

    Facepalm um no I want owners TO be able to pk , BUT when and if they kill someone , that someone does not lose items.
    Reply With Quote  
     

  9. #9  
    Registered Member
    Join Date
    Jul 2012
    Posts
    80
    Thanks given
    0
    Thanks received
    1
    Rep Power
    11
    ohh then make it so that they cant drop in general, or else your going to have to make a whole new meathod in player killing.
    Reply With Quote  
     

  10. #10  
    Registered Member fourshorty's Avatar
    Join Date
    Oct 2013
    Posts
    148
    Thanks given
    17
    Thanks received
    10
    Rep Power
    11
    bump
    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

Similar Threads

  1. Replies: 12
    Last Post: 04-09-2012, 03:35 PM
  2. Replies: 12
    Last Post: 03-31-2012, 02:50 AM
  3. Owner/Admin/Mod/Player Has Logged In! Snippet
    By Lation in forum Snippets
    Replies: 25
    Last Post: 05-22-2010, 08:11 PM
  4. [help]When Npc Kills player emote[help]
    By deathhp in forum Help
    Replies: 0
    Last Post: 11-13-2009, 02:17 PM
  5. No xp from killing players?
    By Intorqueo in forum Help
    Replies: 5
    Last Post: 10-08-2009, 08:27 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •