BlitzKraig / fvtt-RITA

Rudimentary Interactive Tabletop Assistant for FoundryVTT
MIT License
1 stars 1 forks source link

Actors starting with 'A' don't get selected #1

Closed dacaz5 closed 3 years ago

dacaz5 commented 3 years ago

For example, when I say "spawn Archmage" it seems to assume I've said "spawn a Rchmage".

BlitzKraig commented 3 years ago

Hi dacaz5, I'm planning to look at some fuzzy matching, which should help alleviate these sorts of issues. Hopefully I can put together a list of common recognition pitfalls and use them to test.

Thanks for the feedback

BlitzKraig commented 3 years ago

Hi dacaz5, this issue has been solved. Some basic fuzzy matching has been implemented, which should help, but the main problem here was the structure of the command string I had.

spawn (a) (an) *actor matched "Spawn archmage" and parsed the actor name as rchmage, stripping the a due to the optional (a) string. I've updated the structure of all commands to instead use Spawn (a )(an )*actor, meaning it will only strip "a " with a space after.

This will be released in 0.1.0 once I've finished the other features and issues I'm working on.

Thanks for your feedback!