Shield Bash Auto Attack Help

Find the proper support area, Saga-Version.
Forum rules
READ NOW: L2j Forums Rules of Conduct
Post Reply
DeFNaTioN
Posts: 3
Joined: Wed May 21, 2014 8:36 am

Shield Bash Auto Attack Help

Post by DeFNaTioN »

Hey guys i tried searching in the forums for an answer. I really wanted to refrain from asking you all. But I was testing out this new L2j server I just put together and I cant seem to get Shield Bash to work. What i mean by that is when i use shield bash my character doesnt auto attack after doing a bash, the character just stands there after inflicting a sheild bash and i have to hit the attack button to swing a regular attack. What is the fix to this? do i have to change something in the config files or?
HorridoJoho
L2j Senior Developer
L2j Senior Developer
Posts: 795
Joined: Sun Aug 14, 2005 11:27 am

Re: Shield Bash Auto Attack Help

Post by HorridoJoho »

DeFNaTioN wrote:I really wanted to refrain from asking you all.
Why would you? Where else would you ask if you can't solve it?
DeFNaTioN wrote:But I was testing out this new L2j server I just put together and I cant seem to get Shield Bash to work. What i mean by that is when i use shield bash my character doesnt auto attack after doing a bash, the character just stands there after inflicting a sheild bash and i have to hit the attack button to swing a regular attack.
Which version are you using?
I tested on core revision 6541 and dtapack revision 10337 from unstable and it was working fine.
DeFNaTioN
Posts: 3
Joined: Wed May 21, 2014 8:36 am

Re: Shield Bash Auto Attack Help

Post by DeFNaTioN »

FBIagent wrote:Why would you? Where else would you ask if you can't solve it?
FBIagent wrote:Which version are you using?
I tested on core revision 6541 and dtapack revision 10337 from unstable and it was working fine.
Youre right sorry about that. So im pretty new at this but when i went into my l2j-version.properties file i got this

Code: Select all

version=${l2j.revision}        builddate=20140517_1223       detailed info:
And for my l2dp-version.properties file i got this

Code: Select all

version=${l2jdp.revision}      builddate=20140517_1218      detailed info:
Again sorry im really new at this :oops: and I really want to learn :D . Working on a project like this is so much fun! Idk if this would help but im using the SVN download from the links provided on the community board here for the CT2.3 Gracia Final.
HorridoJoho
L2j Senior Developer
L2j Senior Developer
Posts: 795
Joined: Sun Aug 14, 2005 11:27 am

Re: Shield Bash Auto Attack Help

Post by HorridoJoho »

In gracia final (T2.3 branch in svn), attacking after skill use was hardcoded for all skills with the following skill types:
PDAM, BLOW, DRAIN_SOUL, SOW, CHARGEDAM, SPOIL

I extended this, so if another skill type is used, the skill is asked for a property named "nextActionAttack", if that is true it should also send the player to attack.
You just need to apply this patch to your checked out sourcecode:
[pastebin]v4kSFbkP[/pastebin]

So on all skills which does not have one of the skill types above, but you want the player to attack after skill use, you have to go to data/stats/skills and search for the skill.
Then you add the following to the skill:

Code: Select all

 <set name="nextActionAttack" val="true"/> 
The skill definitions are splited up into files which contain skill id ranges. Get the skill id of your skill and then open the xml file where your skill id is in between the numbers the file name tell you.
If you want to search for skill ids, you can press Alt+G in game when you are GM and type in the skill name, then you get a list of skills and the ids.

I didn't tested this but theoretically this should work, it's an almost copy paste from the current beta branch.
User avatar
jurchiks
Posts: 6769
Joined: Sat Sep 19, 2009 4:16 pm
Location: Eastern Europe

Re: Shield Bash Auto Attack Help

Post by jurchiks »

Code: Select all

if (getAI() == null) || .....){        getAI().setIntention(...); <-- WHAT? }
If you have problems, FIRST TRY SOLVING THEM YOURSELF, and if you get errors, TRY TO ANALYZE THEM, and ONLY if you can't help it, THEN ask here.
Otherwise you will never learn anything if all you do is copy-paste!
Discussion breeds innovation.
DeFNaTioN
Posts: 3
Joined: Wed May 21, 2014 8:36 am

Re: Shield Bash Auto Attack Help

Post by DeFNaTioN »

FBIagent wrote:In gracia final (T2.3 branch in svn), attacking after skill use was hardcoded for all skills with the following skill types:
PDAM, BLOW, DRAIN_SOUL, SOW, CHARGEDAM, SPOIL

I extended this, so if another skill type is used, the skill is asked for a property named "nextActionAttack", if that is true it should also send the player to attack.
You just need to apply this patch to your checked out sourcecode:
[pastebin]v4kSFbkP[/pastebin]

So on all skills which does not have one of the skill types above, but you want the player to attack after skill use, you have to go to data/stats/skills and search for the skill.
Then you add the following to the skill:

Code: Select all

 <set name="nextActionAttack" val="true"/> 
The skill definitions are splited up into files which contain skill id ranges. Get the skill id of your skill and then open the xml file where your skill id is in between the numbers the file name tell you.
If you want to search for skill ids, you can press Alt+G in game when you are GM and type in the skill name, then you get a list of skills and the ids.

I didn't tested this but theoretically this should work, it's an almost copy paste from the current beta branch.
Il give it a go when i get home! Thanks i really appreciate you all taking your time on helping me i really appreciate it :)
HorridoJoho
L2j Senior Developer
L2j Senior Developer
Posts: 795
Joined: Sun Aug 14, 2005 11:27 am

Re: Shield Bash Auto Attack Help

Post by HorridoJoho »

jurchiks wrote:

Code: Select all

if (getAI() == null) || .....){        getAI().setIntention(...); <-- WHAT? }
Good find, didn't noticed that, current core has it also like this.

It should be:

Code: Select all

 if (getAI() != null && .... 
NosBit
L2j Veteran
L2j Veteran
Posts: 314
Joined: Mon Mar 11, 2013 4:19 pm

Re: Shield Bash Auto Attack Help

Post by NosBit »

getAI() cant return null :)
Image
Post Reply