Skip to content

Characters focus on other characters when in combat - #938

Open
MrMelbert wants to merge 8 commits into
masterfrom
combat_lock
Open

Characters focus on other characters when in combat#938
MrMelbert wants to merge 8 commits into
masterfrom
combat_lock

Conversation

@MrMelbert

Copy link
Copy Markdown
Owner

When a mob punches, melees, shoots at, or throws something, they will "lock onto" whatever they hit.
This makes the mob constantly face the direction of their target, regardless of if either they or their target moves about.

This effect applies both to player mobs and to ai controlled mobs.
Though for player mobs, the "lock on" effect requires the player be in combat mode to activate.
It also has some additional exceptions (Doesn't lock onto invisible/stealthed mobs, requires line of sight...)

This my attempt to make combat look less like headless chickens running around.
If two combatants are engaged in mutual combat, they will attempt to keep each other in their field of view, instead of constantly doing twirls and twists to try to dodge attacks. However if one combatant is not interested in fighting (i.e. combat mode disabled) they will change direction like normal (so you don't weirdly maintain eye contact while running away).

(I guess this technically has some balance implications with the flash but it's probably actually an improvement because directional based combat is a coinflip currently)

This is inspired by strafe mode (from other downstreams) and strafe combat (from SS14). My thought process was making it an automatic process would make it play out more naturally instead of having to consciously think about it. (Who knows about what happens in practice though)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant