Skip to content

Refactor: NpcNameFinder SearchMode.Fuzzy default for non corpse names and small improvements#506

Merged
Xian55 merged 3 commits intodevfrom
refactor/npc-name-finder-fuzzy-default-for-non-corpse
May 31, 2023
Merged

Refactor: NpcNameFinder SearchMode.Fuzzy default for non corpse names and small improvements#506
Xian55 merged 3 commits intodevfrom
refactor/npc-name-finder-fuzzy-default-for-non-corpse

Conversation

@Xian55
Copy link
Owner

@Xian55 Xian55 commented May 31, 2023

On the Wrath classic PTR there's a new accessibility feature which allows to adjust the minimum size of the Npc names.

The recommended Minimum Character Name Size value is 6 or 8 for 1920x1080 resolution.

image

This greatly helps a NpcNameFinder component! There's one challenge what needs to be tackled meanwhile. As soon as the Minimum Character Name Size is changed from 0 there are some distance based alpha blending going on.

So SearchMode.Simple yields really poor results, only works in really close range. However SearchMode.Fuzzy mode allows to detect shades of that given color. It works really well with friendly(green), neutral(yellow) and enemies(red).

fuzzy_npc_name


For Corpse(grey / RGB=128) type names however, it's a more trickier situation since that shade is way too common in the game so for now SearchMode.Simple mode is used for this case.

fuzzy_npc_name_corpse

Xian55 added 3 commits June 1, 2023 00:44
…ons. Beside Corpse type npc names use SearchMode.Fuzzy for better results. Corpse names(rgb=128) shade are too common, need to find a better way to distingush. Upon DetermineNpcs no longer allocating extra array for the result. Improved FuzzyColor comparison by avoiding Sqrt calculation.
…etter use of stopwatch and stringbuilder for the output.
@Xian55 Xian55 added refactor This ticket concerns the possible simplification of code/data. enhancement This pull request implements a new feature. labels May 31, 2023
@Xian55 Xian55 merged commit 52c345d into dev May 31, 2023
@Xian55 Xian55 deleted the refactor/npc-name-finder-fuzzy-default-for-non-corpse branch May 31, 2023 23:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement This pull request implements a new feature. refactor This ticket concerns the possible simplification of code/data.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant