This is not a Support area! Discuss about the Server here. Non-Server related discussion goes in
Off-Topic Discussion.
trantadoros33
Posts: 8 Joined: Wed Aug 22, 2007 1:13 pm
Post
by trantadoros33 » Sun Jun 14, 2009 6:01 pm
Hello all ,
i am trying to add the following code in doAttack in l2character but when the user tries to use skills they will land .. and i dont want skills to laund if both are nobled
Code: Select all
if (((L2PcInstance) this).isnoble() && ((L2PcInstance) target).isnoble()) { ((L2PcInstance) this).sendMessage("You cant attack a player which is noblesse."); sendPacket(ActionFailed.STATIC_PACKET); return; }
any solutions how to make them not being able to attack with skills as well?
ZaKaX
Posts: 357 Joined: Thu Nov 22, 2007 6:28 am
Location: Somewhere in Asia.
Post
by ZaKaX » Sun Jun 14, 2009 6:04 pm
Take a look under doCast. Btw, Java is case sensitive so isnoble() will not work, isNoble() will
P.S: Weird, very weird idea.
¿ Que dice los cojones de la nina ?
trantadoros33
Posts: 8 Joined: Wed Aug 22, 2007 1:13 pm
Post
by trantadoros33 » Mon Jun 15, 2009 4:36 am
ZaKaX wrote: Take a look under doCast. Btw, Java is case sensitive so isnoble() will not work, isNoble() will
P.S: Weird, very weird idea.
yeah my bad in syntax , its not the problem.
What about this ?
Code: Select all
if(((L2PcInstance)this).isNoble() && (((L2PcInstance)target).isNoble() && skill.getSkillType() == L2SkillType.XX || skill.getSkillType() == L2SkillType.XX))
do you think it will work with those skilltypes?
XX = skillstypes.
trantadoros33
Posts: 8 Joined: Wed Aug 22, 2007 1:13 pm
Post
by trantadoros33 » Wed Jun 17, 2009 5:04 am
will my previous code in my previous post work?
ZaKaX
Posts: 357 Joined: Thu Nov 22, 2007 6:28 am
Location: Somewhere in Asia.
Post
by ZaKaX » Wed Jun 17, 2009 8:36 am
Why don't you just try it?
Correct version....
Code: Select all
if(((L2PcInstance)this).isNoble() && ((L2PcInstance)target).isNoble() && (skill.getSkillType() == L2SkillType.XX || skill.getSkillType() == L2SkillType.XX))
¿ Que dice los cojones de la nina ?
trantadoros33
Posts: 8 Joined: Wed Aug 22, 2007 1:13 pm
Post
by trantadoros33 » Thu Jun 18, 2009 11:17 am
ZaKaX wrote: Why don't you just try it?
Correct version....
Code: Select all
if(((L2PcInstance)this).isNoble() && ((L2PcInstance)target).isNoble() && (skill.getSkillType() == L2SkillType.XX || skill.getSkillType() == L2SkillType.XX))
thanks , is there any easier way to tell them that they cannot use any skill if they try to ?