kolton / d2bot-with-kolbot

d2bot game manager by D3STROY3R with kolbot libs by kolton for d2bs
345 stars 332 forks source link

Weapon Switch #656

Open jelpens opened 6 years ago

jelpens commented 6 years ago

I have a Frenzy Barb set up with 2 Lawbringers on switch to cast decripify against bosses. How can I configure my character so that it attacks with the secondary weapons for the first fury and then switches back to the main weapons after (against diablo and baal)?

spark10z commented 6 years ago

i guess there is no such config in default kolbot atm. preattack does not do enough attack to get decripy.

i have ww barb with lastwish, and i have put one point to frenzy, and i made him to do frenzy a bit after pre-attack to get life tap, then he switch to ww attack to kill monsters. fade and life tap for ww barb works fine for me.

i needed to code script in barbarian.js in common/attack folder and some. if you like, pls check following information... you need to change stat code to confirm getting decryphy than life tap.

and if you like to use Barbarian.js of mine, please do diff with original script and merge only pretap part.. i guess i had made some other useless changes too. hehe

good luck

in common/config.js PreTap: false, in char config Config.PreTap = 147; // false or attack skill to get lifetap 147 = frenzy in common/attack/Barbarian.js https://pastebin.com/kwVY3jTu

Line 34:            if (Config.PreTap && !unit.getState(58) ) {   // && (!me.getState(121) || !Skill.isTimed(Config.AttackSkill[0]))) {
Line 36:                if (Math.round(getDistance(me, unit)) > Skill.getRange(Config.PreTap) || checkCollision(me, unit, 0x4)) {
Line 37:                    if (!Attack.getIntoPosition(unit, Skill.getRange( Config.PreTap ), 0x4)) {
Line 44:                    me.overhead( "pre tap " + Config.PreTap );
Line 45:                    //Skill.cast(Config.PreTap, Skill.getHand(Config.PreTap), unit);
Line 45:                    //Skill.cast(Config.PreTap, Skill.getHand(Config.PreTap), unit);
Line 47:                    this.doCast( unit, Config.PreTap )

...