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;

        }

}

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


×
×
  • Create New...

Important Information

This community uses essential cookies to function properly. Non-essential cookies and third-party services are used only with your consent. Read our Privacy Policy and We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue..