Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Monster tokens throw Polyglot errors #529

Merged
merged 2 commits into from
Sep 9, 2024

Conversation

NekohimeMusou
Copy link
Contributor

@NekohimeMusou NekohimeMusou commented Jul 16, 2024

Whenever you select a monster token with the Polyglot mod enabled, it emits at least one console error telling you that it can't find the actor's languages because system.languages.value is undefined. As far as I know it's basically harmless, but depending on what I'm doing it can spit hundreds or thousands of bright red error messages that make debugging a pain.

This quick fix eliminates the spam by placing an empty array where Polyglot expects to find it: first by moving the template.json definition for the languages field from the PC actor type into the common template shared by both, then adding migration code to correct the behavior for old monsters.

@Rughalt Rughalt self-requested a review September 9, 2024 18:34
@Rughalt Rughalt merged commit c1a81bb into vttred:main Sep 9, 2024
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.

2 participants