Skip to content

Thief script doesn't seem to work BG2

Hi, i've been using the thief controlled script succesfully in BG1, and it's a great tool i'm constantly using (switching between stealth/detecting/combat). But now I imported my FMT-character into BG2 and the script doesn't seem to activate. I tried all thief scripts but none seem to work. In the character stat screen though, the active script is listed correctly.

I also made a FMT from scratch in case i imported some conflicting status but the same problem occurs.

Am i missing something obvious? Is it because i'm still in Irenicus' dungeon? Or might it be a conflict with addons? I'm using:
- Rogue rebalancing
- Icewindification
- SCS
- Ascension
- Tweaks anthology

Thanks for any feedback,
M.

Comments

  • morpheus562morpheus562 Member Posts: 304
    edited September 2023
    Timers in scripts get messed up when exporting/importing into a new game. Use the clua console to do the following and it may resolve your issue:
    C:SetGlobalTimer("RR#HIDE","LOCALS",0)
    

    Another step is to go into your character, set the script to none, and return to the main game screen. Go back and select the script you want for the character and it will do a reset on it.

    On a similar note, my Enhanced Powergaming Scripts are the only scripts I'm aware of that accounts for and prevents this issue from occurring due to imports.
  • jmerryjmerry Member Posts: 3,881
    There is actually a reset for a bunch of timers; this block in the starting area's script starts the process:
    IF
    	Global("BD_DEFAI","GLOBAL",0)
    THEN
    	RESPONSE #100
    		SetGlobal("BD_DEFAI","GLOBAL",1)
    		SetGlobal("BDAI_RESET_TIMERS","GLOBAL",1)
    		ActionOverride(Player1,ChangeAIScript("BDDEFAI",CLASS))
    		Continue()
    END
    

    What next? The rest of the process is the first block in BDDEFAI:
    IF
    	Global("BDAI_RESET_TIMERS","GLOBAL",1)
    THEN
    	RESPONSE #100
    		SetGlobal("BD_Blind","LOCALS",0)
    		SetGlobal("BD_Cast","LOCALS",0)
    		SetGlobal("BD_CLTM","LOCALS",0)
    		SetGlobal("BD_Dharm","LOCALS",0)
    		SetGlobal("BD_DInv","LOCALS",0)
    		SetGlobal("BD_Glitter","LOCALS",0)
    		SetGlobal("BD_Haste","LOCALS",0)
    		SetGlobal("BD_HIDE","LOCALS",0)
    		SetGlobal("BD_Horror","LOCALS",0)
    		SetGlobal("BD_RParal","LOCALS",0)
    		SetGlobal("BD_SCLAR","LOCALS",0)
    		SetGlobal("BD_Slow","LOCALS",0)
    		SetGlobal("BD_Spook","LOCALS",0)
    		SetGlobal("BD_Support","LOCALS",0)
    		SetGlobal("BD_Wand","LOCALS",0)
    		SetGlobal("BDAI_INIT_SKILL","LOCALS",0)
    		SetGlobal("BDAI_INIT_ATTACK","LOCALS",0)
    		SetGlobal("BDAI_INIT_ITEMS","LOCALS",0)
    		SetGlobal("BDAI_RESET_TIMERS","GLOBAL",0)
    		Continue()
    END
    

    Basically, all of the timers that "Advanced AI" uses get reset. But only for player 1, and only if you let the party AI have a moment to run. Import multiple characters, and they won't all reset. And it doesn't help if you're using a different script, with different timer variables.

    That's not ideal. Definite room for improvement.
  • Myriel_of_TorilMyriel_of_Toril Member Posts: 9
    edited September 2023
    Heya,

    Thanks Morpheus562 and jmerry for your respons!

    While trying out your suggestions i stumbled on the very reason the scripts didn't work: party AI was stupidly on 'off' by default after install. I didn't check this earlier, simply because i never understood or used this option for all the years i've been playing the game (unscripted) :#

    Greetings,
    M.

Sign In or Register to comment.