A Project for Chronicle 4 based on L2JServer.


    Buffs only when on party

    Share

    G-hamsteR

    Posts : 60
    Join date : 2013-04-26

    Buffs only when on party

    Post  G-hamsteR on 13th May 2013, 01:52

    Hello everyone,

    I was wondering how I can make it so that someone can use buffs on another player only when they are on the same party. In my server everyone just go in Giran and destroy others' buff sets.
    avatar
    DnR
    Admin
    Admin

    Posts : 1027
    Join date : 2012-12-03

    Re: Buffs only when on party

    Post  DnR on 15th May 2013, 11:49

    G-hamsteR wrote:Hello everyone,

    I was wondering how I can make it so that someone can use buffs on another player only when they are on the same party. In my server everyone just go in Giran and destroy others' buff sets.

    One way is to change targetType of buffs from TARGET_ONE to TARGET_PARTY_MEMBER.
    You will still be able to cast buffs to yourself without party Wink

    G-hamsteR

    Posts : 60
    Join date : 2013-04-26

    Re: Buffs only when on party

    Post  G-hamsteR on 16th May 2013, 01:48

    Thank you very much! I am really grateful for all your help and for giving this pack to us!

    I would like to pay you back somehow. Unfortunately I have no java knowledge. What I am good at is making websites. If you ever need anything, just pm me and I will help you!
    avatar
    DnR
    Admin
    Admin

    Posts : 1027
    Join date : 2012-12-03

    Re: Buffs only when on party

    Post  DnR on 16th May 2013, 18:00

    G-hamsteR wrote:Thank you very much! I am really grateful for all your help and for giving this pack to us!

    I would like to pay you back somehow. Unfortunately I have no java knowledge. What I am good at is making websites. If you ever need anything, just pm me and I will help you!

    Thank you. I will keep that in mind. Smile

    G-hamsteR

    Posts : 60
    Join date : 2013-04-26

    Re: Buffs only when on party

    Post  G-hamsteR on 17th May 2013, 14:07

    DnR wrote:
    G-hamsteR wrote:Hello everyone,

    I was wondering how I can make it so that someone can use buffs on another player only when they are on the same party. In my server everyone just go in Giran and destroy others' buff sets.

    One way is to change targetType of buffs from TARGET_ONE to TARGET_PARTY_MEMBER.
    You will still be able to cast buffs to yourself without party Wink

    Unfortunately it is not working. I am using revision 370.

    roko91

    Posts : 238
    Join date : 2013-01-30
    Age : 26
    Location : Bulgaria

    Re: Buffs only when on party

    Post  roko91 on 17th May 2013, 14:14

    Simply look at some buff which can be cast only on party ... for example Chant of Victory:
    Code:
    <skill id="1363" levels="1" name="Chant of Victory">
      <set name="itemConsumeId" val="3031"/>
      <set name="itemConsumeCount" val="40"/>
      <set name="mpInitialConsume" val="57"/>
      <set name="mpConsume" val="227"/>
      <set name="power" val="20"/>
      <set name="target" val="TARGET_PARTY"/>
      <set name="skillRadius" val="1000"/>
      <set name="hitTime" val="2500"/>
      <set name="reuseDelay" val="1200000"/>
      <set name="skillType" val="HEAL_PERCENT"/>
      <set name="isMagic" val="true"/>
      <set name="operateType" val="OP_ACTIVE"/>
      <set name="buffDuration" val="300000"/>
      <set name="castRange" val="-1"/>
      <set name="effectRange" val="-1"/>
      <for>
        <effect count="1" name="Buff" time="300" val="0" stackOrder="1" stackType="CoV">
          <mul order="0x30" stat="pAtk" val="1.1"/>
          <mul order="0x30" stat="pDef" val="1.2"/>
          <mul order="0x30" stat="rCrit" val="1.2"/>
          <add order="0x40" stat="accCombat" val="4"/>
          <mul order="0x30" stat="pAtkSpd" val="1.2"/>
          <mul order="0x30" stat="mAtkSpd" val="1.2"/>
          <mul order="0x30" stat="cAtk" val="1.2"/>
          <mul order="0x30" stat="mAtk" val="1.20"/>
          <mul order="0x30" stat="mDef" val="1.20"/>
          <mul order="0x30" stat="runSpd" val="0.8"/>
          <mul order="0x30" stat="maxHp" val="1.20"/>
          <mul order="0x30" stat="debuffVuln" val="0.8"/>
        </effect>
      </for>
    </skill>
    Clearly you need this part from here:
    Code:

      <set name="target" val="TARGET_PARTY"/>
    Good luck Smile

    G-hamsteR

    Posts : 60
    Join date : 2013-04-26

    Re: Buffs only when on party

    Post  G-hamsteR on 17th May 2013, 15:06

    roko91 wrote:Simply look at some buff which can be cast only on party ... for example Chant of Victory:
    Code:
    <skill id="1363" levels="1" name="Chant of Victory">
      <set name="itemConsumeId" val="3031"/>
      <set name="itemConsumeCount" val="40"/>
      <set name="mpInitialConsume" val="57"/>
      <set name="mpConsume" val="227"/>
      <set name="power" val="20"/>
      <set name="target" val="TARGET_PARTY"/>
      <set name="skillRadius" val="1000"/>
      <set name="hitTime" val="2500"/>
      <set name="reuseDelay" val="1200000"/>
      <set name="skillType" val="HEAL_PERCENT"/>
      <set name="isMagic" val="true"/>
      <set name="operateType" val="OP_ACTIVE"/>
      <set name="buffDuration" val="300000"/>
      <set name="castRange" val="-1"/>
      <set name="effectRange" val="-1"/>
      <for>
        <effect count="1" name="Buff" time="300" val="0" stackOrder="1" stackType="CoV">
          <mul order="0x30" stat="pAtk" val="1.1"/>
          <mul order="0x30" stat="pDef" val="1.2"/>
          <mul order="0x30" stat="rCrit" val="1.2"/>
          <add order="0x40" stat="accCombat" val="4"/>
          <mul order="0x30" stat="pAtkSpd" val="1.2"/>
          <mul order="0x30" stat="mAtkSpd" val="1.2"/>
          <mul order="0x30" stat="cAtk" val="1.2"/>
          <mul order="0x30" stat="mAtk" val="1.20"/>
          <mul order="0x30" stat="mDef" val="1.20"/>
          <mul order="0x30" stat="runSpd" val="0.8"/>
          <mul order="0x30" stat="maxHp" val="1.20"/>
          <mul order="0x30" stat="debuffVuln" val="0.8"/>
        </effect>
      </for>
    </skill>
    Clearly you need this part from here:
    Code:

      <set name="target" val="TARGET_PARTY"/>
    Good luck Smile

    I think that if I change it to TARGET_PARTY, it will be casted upon all party members, and not just the targeted party member.

    roko91

    Posts : 238
    Join date : 2013-01-30
    Age : 26
    Location : Bulgaria

    Re: Buffs only when on party

    Post  roko91 on 17th May 2013, 21:42

    DnR is right: "TARGET_PARTY_MEMBER" is what you looking for. I searched in all skills xmls and my conclusion is that it isn't implemented in L2j C4 because it wasn't necessary. For example "Berserker spirit" isn't only for party on C4 (I think NCSOFT made it only for party since C5). If you have java knowledge you can try to adapt the implementation from post C4 java sources.
    avatar
    DnR
    Admin
    Admin

    Posts : 1027
    Join date : 2012-12-03

    Re: Buffs only when on party

    Post  DnR on 18th May 2013, 10:19

    roko91 wrote:DnR is right: "TARGET_PARTY_MEMBER" is what you looking for. I searched in all skills xmls and my conclusion is that it isn't implemented in L2j C4 because it wasn't necessary. For example "Berserker spirit" isn't only for party on C4 (I think NCSOFT made it only for party since C5). If you have java knowledge you can try to adapt the implementation from post C4 java sources.

    It' s already in core. I added it just for admins to use it in a case like this. But i found a wrong check in Target Type. It' s going to be fixed in new revision. Please be patient.
    avatar
    DnR
    Admin
    Admin

    Posts : 1027
    Join date : 2012-12-03

    Re: Buffs only when on party

    Post  DnR on 18th May 2013, 22:45

    Should be working with latest revision. Smile

    Sponsored content

    Re: Buffs only when on party

    Post  Sponsored content


      Current date/time is 19th November 2017, 02:56