Jump to content


Photo

Demons attacking their summoners w/ them defending themselves.


  • Please log in to reply
6 replies to this topic

#1 Ulb

Ulb
  • Modder
  • 373 posts

Posted 17 June 2014 - 11:24 AM

Hey there,

 

I've run into some issues with my current BG2 (BG:ToB) installation.

 

It appears arcanoloths and other summoned demons attack their summoners if there are no other targets around.

 

While this is 'as advertized', the summoning npcs seem to not recognize the attacks and will just stand there without defending themselves until they are dead.

 

I'm aware that this might not be aTweaks's fault but since I wouldn't know where else to lay blame, I'm posting here first. :P

 

 

My uneducated guess would be that this is somehow related to the demons aligning themselves to their summoner's alignment?

 

I encountered that behavior while fighting (or rather hiding from) Lavok in the Planar Sphere. With my party invisible or hiding in the nearby rooms, the summoned arcanoloth would just kill Lavok without him doing anything.

(He did summon a few shades -which didn't attack the arcanoloth either- but besides that he just stood there and did nothing.)

 

 

I've included my weidu-log just in case it is relevant.

 

(I know the end of my installation is a bit messy but I doubt that it causes any interference with the scrips involved in the demons' or their summoners' behavior.)

 

Spoiler


Edited by Ulb, 17 June 2014 - 11:25 AM.


#2 Wisp

Wisp
  • Modder
  • 1353 posts

Posted 17 June 2014 - 12:21 PM

IIRC, this is at its root a SCS bug, which has certain casters summoning player-intended critters for some spells (rather than the SCS-intended ones). Or maybe that bug was fixed already, I forget. If you want to confirm, Lavok should be using dw#cacof.spl (which is a Cacofiend analogue that summons a well-behaved fiend, ultimately resolving into fl#arcsu.cre for LC_NEUTRAL casters), and not WIZARD_CACOFIEND (which is the player version of the spell).

 

Though I was never able to figure out why the fiend turns on its summoner. I couldn't reproduce it and I can see no reason in the code. I can only assume there's some confounding factor that was not reproduced in my test setting. And until it causes a problem in an otherwise unbugged scenario, I don't think I will feel like screwing around with BW* and hope I stumble upon the reason.

 

 

Also, BW*'s installation order is objectively wrong. All of RR goes before any of aTweaks. I don't care if it seems to work now. Any compatibilty concerns between RR and aTweaks assume a fixed relationship between the two and I might do something tomorrow that breaks BW*'s current house of cards. Edit: unless this is one of the messy parts? In which case, yeah, it's wrong.


Edited by Wisp, 17 June 2014 - 12:27 PM.


#3 Ulb

Ulb
  • Modder
  • 373 posts

Posted 17 June 2014 - 12:52 PM

I just checked, Lavok uses DW#2NEC9.BCS as his default script which contains the following piece of code:

 

 

IF

!GlobalTimerNotExpired("castspell","LOCALS")
HaveSpell(WIZARD_CACOFIEND)
CheckStatLT(Myself,50,SPELLFAILUREMAGE)
OR(2)
!CheckStatGT(Myself,0,WIZARD_IMPROVED_ALACRITY)
GlobalTimerNotExpired("alacritybutlongspellsanyway","LOCALS")
THEN
RESPONSE #100
SetGlobalTimer("castspell","LOCALS",ONE_ROUND)
SpellNoDecRES("fl#canpc",Myself) // Cacofiend
RemoveSpell(WIZARD_CACOFIEND)
RESPONSE #50
Continue()
END

 

 

So while it's not dw#cacof.spl, fl#canpc.spl sounds like it is the right (aTweaks version) spell for npcs.

 

However, fl#canpc.spl actually summons FL#SARCA.CRE and not FL#ARCSU.CRE which, if I got that right, is part of the issue?

 

If that is the case, it would appear to be more of an aTweaks problem since fl# is an aTweak tag?

 

 

 

 unless this is one of the messy parts? In which case, yeah, it's wrong.

 

Nope, the messy part is everything after generalized biffing. The stuff that happens before is/should be in default BW(P/S) order.

 

Anyway, thanks for your quick answer.

 

If there is anything I can do to shed some more light on that issue, please let me know.

(I would rather not remove aTweaks or SCS from my installation order...)

 

 



#4 The Imp

The Imp

    Not good, see EVIL is better. You'll LIVE.

  • Member
  • 5155 posts

Posted 17 June 2014 - 02:03 PM

Also, BW*'s installation order is objectively wrong. All of RR goes before any of aTweaks. I don't care if it seems to work now. Any compatibilty concerns between RR and aTweaks assume a fixed relationship between the two and I might do something tomorrow that breaks BW*'s current house of cards.
You might want to warn Quiet about it... say give him a fair warning, like the time of two minutes, for example ... :devil:
Yes, unfortunately the BWS's last update didn't actually touch the RR component 2, 5, 12 and 999 placements in the install order, the rest are already on top of the aTweaks.
I just checked, Lavok uses DW#2NEC9.BCS as his default script which contains...
You know, you could always --change-log the file and find which added that... or Lavok's .cre file and find out a bit other things.

Edited by The Imp, 17 June 2014 - 02:12 PM.

Yep, Jarno Mikkola. my Mega Mod FAQ. Use of the BWS, and how to use it(scroll down that post a bit). 
OK, desert dweller, welcome to the sanity, you are free to search for the limit, it's out there, we drew it in the sand. Ouh, actually it was still snow then.. but anyways.


#5 Wisp

Wisp
  • Modder
  • 1353 posts

Posted 18 June 2014 - 10:03 AM

So while it's not dw#cacof.spl, fl#canpc.spl sounds like it is the right (aTweaks version) spell for npcs.
 
However, fl#canpc.spl actually summons FL#SARCA.CRE and not FL#ARCSU.CRE which, if I got that right, is part of the issue?
 
If that is the case, it would appear to be more of an aTweaks problem since fl# is an aTweak tag?

If you uninstall "Further Revised Fiend Summoning", Lavok would be using WIZARD_CACOFIEND. fl#canpc just isolates the old WIZARD_CACOFIEND from the changes made by "Further Revised Fiend Summoning". (Sorry, I didn't look that far into your log.)

If you can reproduce this, you can try installing the enclosed code and see which block corresponds to the Arcanaloth going after Lavok. Bear in mind a lot of those blocks will be about the Arcanaloth casting spells and attacking, so you need the block reported before that.
COPY_EXISTING fl#sarca.bcs override
                                fl#arcsu.bcs override
	SET x = 0 - 1
	DECOMPILE_BCS_TO_BAF
		REPLACE_EVALUATE ~\(RESPONSE #[0-9]+\)~ BEGIN
						x += 1
				END "\1
		ActionOverride(Player1,DisplayString(Myself,~Running block %x% of %SOURCE_RES%.BCS~))"
	COMPILE_BAF_TO_BCS

Also bear in mind there may be other scripts involved here (almost certainly so if it's another mod interferring), so feel free to toss in additional scripts if you think they may be relevant (and/or remove scripts if you don't think they are relevant).

#6 The Imp

The Imp

    Not good, see EVIL is better. You'll LIVE.

  • Member
  • 5155 posts

Posted 18 June 2014 - 10:39 AM

Also bear in mind there may be other scripts involved here (almost certainly so if it's another mod interferring), so feel free to toss in additional scripts if you think they may be relevant (and/or remove scripts if you don't think they are relevant).

Or he could install the LSTest mod to cover every single one of scripts and fish out what the .cre is doing.


Yep, Jarno Mikkola. my Mega Mod FAQ. Use of the BWS, and how to use it(scroll down that post a bit). 
OK, desert dweller, welcome to the sanity, you are free to search for the limit, it's out there, we drew it in the sand. Ouh, actually it was still snow then.. but anyways.


#7 Ulb

Ulb
  • Modder
  • 373 posts

Posted 18 June 2014 - 05:35 PM

I'm bad with keeping multiple saved games, but I'll run one of those methods once I encoutner the next demon whacking it's summoner. :)