Skip to content

Conversation

@petchema
Copy link
Collaborator

@petchema petchema commented Jul 26, 2023

PR #1861 was added to prevent caster enemies from nuking themselves with spells at range in the presence of low obstacles.

A side effect of this PR however, is that daedra lords in the "crossbow room" near the end of Mantellan Crux stopped shooting at the player altogether, making this room much less threatening.

This new PR checks for obstacles a bit in front of the enemies, so they can still cast from behind thin obstacles (rationale: spells start from arm's reach). It's a bit crude, for example it doesn't change from where the spells will be really cast. While some spells get thru, daedra lords sometimes nuke themselves.

PR Interkarma#1861 was added to prevent caster enemies from nuking themselves with
spells at range in the presence of low obstacles.

A side effect of this PR however, is that daedra lords in the "crossbow
room" near the end of Mantellan Crux stopped shooting at the player
altogether, making this room much less threatening.

This new PR checks for obstacles a bit in front of the enemies, so they
can still cast from behind thin obstacles (rationale: spells start from
arm's reach). It's a bit crude, for example it doesn't change from where
the spells will be really cast, but from testing different casters
(namely, beside Mantellan Crux's daedra lords: Karolys lich and
Gortwog's shaman in entrance of Orsinium), I haven't experienced
regressions.
@petchema petchema added regression wip Work in progress labels Jul 26, 2023
@petchema
Copy link
Collaborator Author

Casters from the main quest, for tests
Orsinium Shaman.zip
Karolys.zip
Daedra Lords.zip

Pierre Etchemaite added 2 commits August 2, 2023 18:32
DaggerfallMissile makes missiles originate in from of sender (position +
dir * collisionRadius). Just make EnemyMotor make the same assumption.
Somewhat help Daedra Lords (and Sentinel's Wraith) cast more often.
Casting from a higher position could also help Daedra Lords. I didn't
want to add enemy type specific logic, though.

Spell origin sphere is now disconnected from the caster's capsule (0.9 >
0.45 + 0.4), which must be why it works. I haven't found an example of
caster trying to shoot the player with no visibility, but can it happen?
@petchema petchema removed the wip Work in progress label Aug 2, 2023
@petchema
Copy link
Collaborator Author

petchema commented Aug 2, 2023

Update: casting origin is now consistent between EnemyMotor and DaggerfallMissile, enemies should cast safely again.
As an improvement, casting from a higher position (instead of only ahead) would help daedra lords to cast from a wider variety of angles; But that may require adding enemy-type specific logic.

@Interkarma
Copy link
Owner

You're a treasure, thank you Pango! I appreciate the saves for testing. :)

@Interkarma Interkarma merged commit e9e19cc into Interkarma:master Aug 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants