TheLastScrub / delta-green-foundry-vtt-system

A Foundry VTT game system for Delta Green: The RPG! This is a fan made work that is unaffiliated with Shane Ivey or Arc Dream Publishing, published under the Delta Green Community license. http://www.delta-green.com https://foundryvtt.com/
MIT License
26 stars 24 forks source link

Error when opening pre-gen character sheet #120

Closed Ypnos666 closed 3 months ago

Ypnos666 commented 4 months ago

v11.315

image
TheLastScrub commented 4 months ago

Can you give a little more information? I tried it on Foundry v11.315 and I seem to be able to open Agent sheets from the Pregen Agents compendium without any errors. Are you using a language other than English? If so, which one?

jalensailin commented 4 months ago

Is this an error preventing you from opening the sheet or simply a warning telling you that you are missing a translation? We need more information to be able to help ya

TheLastScrub commented 4 months ago

@jalensailin this warning will pop up if (as the message implies) those translation keys are missing. It's a region-specific issue, we'd need @Ypnos666 to give us more information to remedy their specific case. But I think because this is the way I wrote translating the header buttons:

image

If a bilingual player has their Foundry language preference set to a language DG is not translated to (Korean for instance, perhaps in order to have the general Foundry GUI in that language), they might still be happily playing with the DG system in English BUT they will get this warning every single time they open a character sheet.

Considering that, I think I should just change it from an alert to just log it to the console instead. Your thoughts?

Ypnos666 commented 4 months ago

Hi, sorry for late reply, this went to junk mail.

I am using standard English Foundry, no bilingual options selected.

I have just created a brand new world, using only the DG game system and no modules switched on. The only action I took was to import the Agent pregens from the compendium and then opened a character sheet. I still get the same warning.

It does not prevent me from opening the character sheet.

Edit 1: I am using DG game system 1.4.4

Edit 2: I have found the Luck button at the top of the character sheet and it works fine when I click it Thanks

TheLastScrub commented 4 months ago

Very strange. I am running DG 1.4.4 and Foundry v11.315 (so exact same as you), and do not see any issues with it, even if I import the actors. What does your Foundry host environment look like (Windows/Linux, Electron client or NodeJS or Forge)? And what browser are you using?

Or if it's not an issue anymore now that you've found the luck button, I can close the bug out? I will make a slight tweak to the code to try to avoid that warning. But if everything (Foundry and DG) are English, don't think it would do anything for you...

Ypnos666 commented 4 months ago

I may have found the problem. Looked through the settings and the language is actually set to "Latin - Prettier Login Screen", as I had a css mod that makes the login screen look nicer. So while it is English, it's not "standard" standard English, so I'm guessing your code is seeing it as another language.

image

Sorry for the faulty information!

Regarding the other question, I'm running Foundry in Docker.

Thanks

TheLastScrub commented 4 months ago

Ah thanks, yes that would likely cause the issue as if it were any non-translated language choice... I am going to make a change where this issue will be still there (because it will still fail to localize) but it just won't visibly alert about it anymore so it won't be as annoying.

TheLastScrub commented 3 months ago

Should be in v1.4.6 when I package and release it.