Skip to content

AI Script Ranged Option will select unarmed or no proficiency melee weapons over proficient weapons

LaceLace Member Posts: 74
I noticed this in both SoD and BG2.

In SoD, when Corwin switched from using her ranged weapon to using a melee weapon, she would select unarmed or a weapon she was not proficient in (i.e. a dagger) instead of choosing the halberd she was proficient in.

I've switched my characters off using the ranged script as a quick fix for me, but I thought I'd mention it here in case others have noticed this as well.

Comments

  • sarevok57sarevok57 Member Posts: 6,002
    which script exactly the one you were using? advanced AI or arang? I find that the advanced AI script with prefer ranged weapons works really well, where arang works well most of the time but not as well as the advanced AI one does
  • LaceLace Member Posts: 74
    I was using ARANG. I played the games a long time ago, so I didn't notice the check boxes to control the character on advanced AI (I just switched because I don't like AI settings that auto-cast spells lol). Now that I'm taking a closer look at it, I think I'll start using those options, except for my thieves and clerics (for finer control of turn undead and find traps). I prefer thief control and cleric control there.
  • LaceLace Member Posts: 74
    edited January 2017
    Hmm, I've been playing on several different AI options now, and it seems that the scripts, all of them, bug out when my character(s) are using 2 handed weapons. Minsc will change from his Sword of Chaos to the spare Long Sword+1 I'd been keeping in his spare slot, Jaheira will go unarmed before she'll use her and quarterstaff+2. This jives with what I experienced with Corwin in SoD as well (she was the only char holding a 2 handed weapon that I'd allow in melee combat lol).

    Could it be because I'm also storing shields in their shield slots? Does that impact how the game decides which melee weapon is better?

    EDIT: I also switched off the Advanced AI setting, because I found that every once in a while, the game would still auto-cast spells every once in a while (usually defensive spells, such as stone skin with Neera), even with the check box unmarked.
  • GallowglassGallowglass Member Posts: 3,356
    I always run with AI off, so I've no experience with the AI scripts. However ...
    Lace said:

    Could it be because I'm also storing shields in their shield slots? Does that impact how the game decides which melee weapon is better?

    ... this sounds like a plausible explanation. Have you tried unequipping the Shields and testing again to see if it makes any difference to script behaviour?
  • LaceLace Member Posts: 74
    That was exactly it. When the shield is unequipped, they stop switching off their two-handed weapons. It seems that the specific trigger that was causing them to change weapons was when an enemy unit hit them, so I guess it was rating the better defense as a higher priority then.

    That's a pretty easy fix for Minsc, since both his primary melee and ranged weapons are two handed for now, so I just sold off the shield, but until I go questing for a better melee weapon for Jaheira, I've been running her primarily ranged with a sling, and with a quarterstaff+2 as her backup weapon. I want that shield when she's using her sling, so I have to manually remove the shield at the start of any melee encounter for her, because she will almost always get hit and switch to unarmed combat, even if that means that she can't hit enemies anymore (i.e. vs shadows).

    On a lighter note, I'm thinking of this from a roleplaying perspective. Imagine dropping your weapon and swinging your shield at your enemies every time you get hit lmao.
  • GallowglassGallowglass Member Posts: 3,356
    Hmm, I reckon that's a poorly-designed script, then.

    Note to devs: it'd make for better scripting if the "switch from ranged to melee" code prioritised melee weapon selection by comparing weapon proficiency points (instead of resultant AC) between equipped weapons (and specifically excluded fists except for a Monk).
  • LaceLace Member Posts: 74
    edited January 2017
    Sorry, I don't think I was clear enough in my previous post. The trigger wasn't isolated to ranged AI scripts, it was triggered by the character getting hit by an opponent's attack. I noticed it triggered switches from one melee weapon to another as well, and on several different AI script settings (passive, standard attack, and advanced AI scripts in particular).
Sign In or Register to comment.