Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Dark Dreams of Furiae - a new module for NWN:EE! Buy now
Attention, new and old users! Please read the new rules of conduct for the forums, and we hope you enjoy your stay!

Summoned Ettercaps does not apply poison?

MWOMWO Member Posts: 197
Hello again!

Another question for you developers out there.

I've been doing some tests as of late regarding the game, e.g. trying out the game mechanics.

Summoned Ettercaps with "Monster Summoning III" doesn't seem to affect the target with its natural poison attacks. Shouldn't ettercaps apply poison when hitting an enemy?

1frlit18d6g2.png

Comments

  • kjeronkjeron Member Posts: 2,151
    edited February 16
    They have a 40% chance to switch to their poisoning attack every 2 rounds while idle, and a 60% chance to switch back to their normal attack. Same as non-summoned ettercaps. I believe it requires Party AI to be turned on for summoned creatures though.

    Grond0JuliusBorisovMWO
  • Luke93Luke93 Member, Mobile Tester Posts: 1,338
    kjeron wrote: »
    I believe it requires Party AI to be turned on for summoned creatures though.

    Why?

  • kjeronkjeron Member Posts: 2,151
    Luke93 wrote: »
    Why?
    I couldn't remember whether summoned creature's were affected by hte "Party AI" button, they're not, so it shouldn't matter.

  • Luke93Luke93 Member, Mobile Tester Posts: 1,338
    edited February 19
    kjeron wrote: »
    Luke93 wrote: »
    Why?
    I couldn't remember whether summoned creature's were affected by hte "Party AI" button, they're not, so it shouldn't matter.

    Yep. Moreover, it's not true they need to be idle (yeah, ETTERCAP.BCS is a bit strange...)
    IF
    	See(NearestEnemyOf(Myself))
    	Delay(12)
    THEN
    	RESPONSE #60
    		SelectWeaponAbility(SLOT_WEAPON0,0)
    		AttackReevaluate(NearestEnemyOf(Myself),15)
    	RESPONSE #40
    		SelectWeaponAbility(SLOT_WEAPON1,0)
    		AttackReevaluate(NearestEnemyOf(Myself),15)
    END
    

  • kjeronkjeron Member Posts: 2,151
    "idle" might not be the best term, but they can get stuck in the attack cycle, preventing them from changing weapons until their target dies.

  • Luke93Luke93 Member, Mobile Tester Posts: 1,338
    kjeron wrote: »
    "idle" might not be the best term, but they can get stuck in the attack cycle, preventing them from changing weapons until their target dies.

    Interesting. Please, could you elaborate? Is it because of that Continue()?

  • BubbBubb Member Posts: 759
    It's due to how AttackReevaluate doesn't terminate until all valid targets are dead. The engine won't re-execute a script block that's currently running - even if it "should" due to all the triggers holding; (note that this still halts the script-pass as if it had chosen the block).

    So, the weapon-switching block won't run again until the AttackReevaluate ends. This effectively means that the script does a single-time weapon select at the beginning of every battle, 60% chance for non-poison attack, and 40% chance for poison attack.

  • Luke93Luke93 Member, Mobile Tester Posts: 1,338
    edited February 20
    @Bubb

    Ah, here we go again.

    As we already discussed, nothing changes if the Ettercap is in "chase" mode, right? When 'ReevaluationPeriod' is up, it will simply switch to the nearest target. So the following block
    IF
    	!GlobalTimerNotExpired("BD_PICK_WEAPON","LOCALS")
    	OR(2)
    		ActionListEmpty()
    		Global("BD_FIRST_WEAPON","LOCALS",0)
    THEN
    	RESPONSE #60
    		SelectWeaponAbility(SLOT_WEAPON0,0)
    		SetGlobalTimer("BD_PICK_WEAPON","LOCALS",TWO_ROUNDS)
    		SetGlobal("BD_FIRST_WEAPON","LOCALS",1)
    		Continue()
    	RESPONSE #40
    		SelectWeaponAbility(SLOT_WEAPON1,0)
    		SetGlobalTimer("BD_PICK_WEAPON","LOCALS",TWO_ROUNDS)
    		SetGlobal("BD_FIRST_WEAPON","LOCALS",1)
    		Continue()
    END
    

    won't be executed because both 'ActionListEmpty()' and 'Global("BD_FIRST_WEAPON","LOCALS",0)' are FALSE; moreover, the next block
    IF
    	See(NearestEnemyOf(Myself))
    	Delay(12)
    THEN
    	RESPONSE #60
    		SelectWeaponAbility(SLOT_WEAPON0,0)
    		AttackReevaluate(NearestEnemyOf(Myself),15)
    	RESPONSE #40
    		SelectWeaponAbility(SLOT_WEAPON1,0)
    		AttackReevaluate(NearestEnemyOf(Myself),15)
    END
    

    won't be executed because it's currently running (even if both 'See(NearestEnemyOf(Myself))' and 'Delay(12)' are TRUE).

    A quick fix would be that of replacing 'AttackReevaluate()' with 'AttackOneRound()' (which does terminate after one round...)

    Post edited by Luke93 on
  • CamDawgCamDawg Member, Developer Posts: 3,413
    edited February 20
    This was something changed in 2.5, when it was noted that neither ettercaps nor wyverns use poison when summoned. The original BG devs gave ettercaps and wyverns multiple weapons to reflect their PnP attacks--they also use different attack animations, e.g. the wyvern attack that poisons is a tail sting while its non-poison attack is a bite or claw IIRC.

    When summoned they just used their main, non-poison attack, so we scripted the ability to switch weapons occasionally. It's scripted a bit oddly since the priority was to never interrupt user instructions--outside of that it's their existing combat script.

    JuliusBorisovStummvonBordwehr
  • Luke93Luke93 Member, Mobile Tester Posts: 1,338
    edited February 20
    @CamDawg

    You might want to try the following one:
    IF
    	StateCheck(Myself,STATE_PANIC)
    THEN
    	RESPONSE #100
    		RandomWalkContinuous()
    END
    
    IF
    	!GlobalTimerNotExpired("BD_PICK_WEAPON","LOCALS")
    	OR(2)
    		Allegiance(Myself,EVILCUTOFF)
    		ActionListEmpty()
    THEN
    	RESPONSE #60
    		SelectWeaponAbility(SLOT_WEAPON0,0)
    		SetGlobalTimer("BD_PICK_WEAPON","LOCALS",TWO_ROUNDS)
    		Continue()
    	RESPONSE #40
    		SelectWeaponAbility(SLOT_WEAPON1,0)
    		SetGlobalTimer("BD_PICK_WEAPON","LOCALS",TWO_ROUNDS)
    		Continue()
    END
    
    IF
    	See(NearestEnemyOf(Myself))
    	OR(2)
    		Allegiance(Myself,EVILCUTOFF)
    		ActionListEmpty()
    THEN
    	RESPONSE #100
    		AttackOneRound(NearestEnemyOf(Myself))
    END
    

  • MWOMWO Member Posts: 197
    Okey... thanks for the insights!

Sign In or Register to comment.