Jump to content
  • 0

[help]


Question

4 answers to this question

Recommended Posts

  • 0
Posted

Αυτα που σου εχω checkarei φιλε μου look:

 

package net.sf.l2j.gameserver;

 

import java.net.InetAddress;

 

import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance;

import net.sf.l2j.gameserver.network.L2GameClient;

 

public class AntiFeed

{

public static boolean antiFeed(L2PcInstance killed, L2PcInstance killer)

        {

               

                final L2GameClient killedClient = killed.getClient();

                final L2GameClient killerClient = killer.getClient();

               

                InetAddress killerip = killerClient.getConnection().getInetAddress();

                InetAddress killedip = killedClient.getConnection().getInetAddress();                

               

                //Check the IP address.

                if (killerip.equals(killedip)) return false;

                //Check party

                if (killer.getParty().equals(killed.getParty())) return false;

                //Check clan

                if (killer.getClanId() == killed.getClanId()) return false;

               

 

 

                return true;

        }

}

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...