Page 1 of 1

Trade Scam.

Posted: Mon Sep 02, 2013 2:50 am
by maxstyleboy
How to block sending trade to character in combat or flag?

thanks!

:twisted:

Re: Trade Scam.

Posted: Mon Sep 02, 2013 6:45 am
by lion
add check in TradeRequest

Re: Trade Scam.

Posted: Wed Sep 04, 2013 7:29 am
by Micr0
add this in TradeRequest.java

Code: Select all

        if (!target.isPlayer())        {            player.sendPacket(SystemMessageId.INCORRECT_TARGET);            return;        }                +if(player.isInCombat())        +{        +   player.sendMessage("You cannot trade while you are in a combat state.");        +   return;        +} 

Re: Trade Scam.

Posted: Wed Sep 04, 2013 10:24 am
by Luna
It only blocks when the target is in flag state, not when it is in combat.

Re: Trade Scam.

Posted: Wed Sep 04, 2013 6:26 pm
by maxstyleboy

Code: Select all

===================================================================--- TradeRequest.java@@ -138,6 +138,18 @@            return;        }        +       if (partner.isInCombat())+       {+           player.sendMessage("That person is in combat.");+           return;+       }+       +       if (player.isInCombat())+       {+           player.sendMessage("You cannot trade while in combat.");+           return;+       }+               if (BlockList.isBlocked(partner, player))        {            sm = SystemMessage.getSystemMessage(SystemMessageId.S1_HAS_ADDED_YOU_TO_IGNORE_LIST);
Thanks :)

:lol:

Re: Trade Scam.

Posted: Wed Sep 04, 2013 6:32 pm
by Konstantinos
maxstyleboy wrote:How to block sending trade to character in combat or flag?

thanks!

:twisted:
Do you have any problem with that?

Re: Trade Scam.

Posted: Wed Sep 04, 2013 7:21 pm
by Luna

Code: Select all

[javac]         if (partner.isInCombat())[javac]             ^[javac]   symbol:   variable partner[javac]   location: class TradeRequest[javac]  1 error
:s

Re: Trade Scam.

Posted: Wed Sep 04, 2013 11:20 pm
by tukune
:!: if (player.isInCombat() || player.getPvpFlag() > 0)

Re: Trade Scam.

Posted: Thu Sep 05, 2013 8:32 am
by Luna
It works, thanks tho ;)

Re: Trade Scam.

Posted: Fri Sep 06, 2013 4:48 am
by maxstyleboy
Konstantinos wrote:
maxstyleboy wrote:How to block sending trade to character in combat or flag?

thanks!

:twisted:
Do you have any problem with that?

Yes, players scam in siege!
If you request trade for any player, this player cannot use skills...

Re: Trade Scam.

Posted: Fri Sep 06, 2013 6:56 am
by Konstantinos
maxstyleboy wrote:
Konstantinos wrote:
maxstyleboy wrote:How to block sending trade to character in combat or flag?

thanks!

:twisted:
Do you have any problem with that?

Yes, players scam in siege!
If you request trade for any player, this player cannot use skills...
thanks.

Re: Trade Scam.

Posted: Sat Sep 07, 2013 10:18 am
by Konstantinos
maxstyleboy wrote:

Code: Select all

===================================================================--- TradeRequest.java@@ -138,6 +138,18 @@            return;        }        +       if (partner.isInCombat())+       {+           player.sendMessage("That person is in combat.");+           return;+       }+       +       if (player.isInCombat())+       {+           player.sendMessage("You cannot trade while in combat.");+           return;+       }+               if (BlockList.isBlocked(partner, player))        {            sm = SystemMessage.getSystemMessage(SystemMessageId.S1_HAS_ADDED_YOU_TO_IGNORE_LIST);
Thanks :)

:lol:
ty i have to check that bug :)

Re: Trade Scam.

Posted: Sun Sep 15, 2013 12:10 am
by Pandragon
:D

Code: Select all

        if (partner.isInCombat() || (partner.getPvpFlag() > 0))        {            player.sendMessage("That person is in combat.");            return;        }                if (player.isInCombat() || (player.getPvpFlag() > 0))        {            player.sendMessage("You cannot trade while in combat.");            return;        }