Update v1.0.3 - 07.09.2023
Update v1.0.3 available, which fixes the text loading problem mentioned in previous posts.
Thanks to @ChimaereJade for their help.
ODW - Multi-Language System Plugin
● ARCHIVED · READ-ONLY
-
-
Hey there,
I encountered a problem when displaying a state name/icon in battle (using VisuStella VisualStateEffect plugin). Whenever an actor is affected/hit with a state, the "${xxxx}" part is interpreted as "space". Therefore the state is diplayed as followed:
Code:"[icon] +name".
Is there any way to fix this? In all other circumstances, the icon is displayed next to the name (for example for skills). I am using the latest version of your plugin.
Any help would be appreciated.
Regards
Lufos -
Hi @Lufos
I'll try to help, but as the VisualStateEffect plugin is a paid plugin, I don't normally do support, as it's impossible for me to test it.
So first of all, could you send me a screenshot of the state message as set up in the RMMZ editor (where you wrote ${...}), and a screenshot of the result in game.
Secondly, have you tried to:
- Put all the text "[icon]+${xxx}+name" into a translated text => ${[icon]+xxx+name}
- Change the plugin order (mine before VS)
Thank you. -
result:
Changing the order didn't work.
Skill:
-
Oops sorry, I forgot to also ask for the text in your JSON files for state and skill. With that, I'll be able to do some research and possibly contact VS for patch suggestions.
Edit: did you enabled the text and icon overlay in the general settings of the VisualStateEffect plugin? Or use any of the notetag for that? -
Thank you for taking a look.
state:
Code:"ST062.Wound1.Name": "Light Wound",
and for a skill:
Code:"SK001.Attack.Name": "Attack",
I did enable pop-ups and state overlays (this state has no overlay). I did not use any notetags for that. -
At first glance, the problem shouldn't be with my plugin. In your JSON file, the state text contains nothing but the spelled-out text, and it's displayed correctly as shown in your screenshot.
This looks more like a problem with displaying graphic/text blocks, where the width is larger than the icon or text to be displayed. I don't know if there's a way to configure this with the VisualStateEffect plugin. What makes me say this is that the total width of the (invisible) block that starts at the left edge of the icon and runs to the right edge of the end of the state text is perfectly centered on the impacted character (as in this example image).
Another possible reason, which is certainly the cause now that I think more about it, is that the width of the text block is calculated not on the number of characters in the state text, but on the code from the editor... which would explain why the state text is aligned so far to the right.
Code:${ST062.Wound1.Name} Light Wound => More characters to display with the code than the text = width bigger!
To be sure, replace ${ST062.Wound1.Name} in the state name field of the RMMZ editor with the Light Wound text displayed, and test again. If the icon is perfectly aligned with the text, this hypothesis will be confirmed. But if this is the case, I won't be able to offer a solution, as I'd need to access the VisualStateEffect plugin code to patch the offending function(s)... which isn't possible as things stand. -
Yes, normal text (wothout ${}) works as intended. Also: the longer the text code, the more spaces. ${xxxx} is shorter/has less spaces than ${xxxxxxxxxxxx}.
thanks for checking, tho. -
Hi, I found a really strange bug. So, I just now switched the editor that I use for .json files in my game from Notepad++ to VisualStudio, and now this cryptic error shows up, for whatever reason. I checked every single .json file in the "languages" folder (of which contents I did even provide, for easier debugging of this error, and both VS and an online JSON validator show that these files are perfectly valid. The problem doesn't happen without your plugin, and the error itself doesn't provide me with the information where exactly I messed up my JSON (while the game's screen is all black). This error completely disallows me from testing my game without all my language text going AWOL, and I wanted to drop at least a commit today :kaosigh:
-
so far I checked your battle.json, it has no opening { and closing }
you might as well add those.
it should work after that, so check your other files as well to see if those
are correct or not. -
Dunno what happened with the .json files in that .zip file or on your end, but in the files on my PC, both battle.json files have the opening and ending curly brackets, and all other .json files also have these brackets where they should be. So, I really don't know where the issue could stem from :kaodes:
-
is in the "en" folder which has no { and } on battle.json.
I didn't check the rest, so if it has everything, than add those and it might work.
I dont own MZ so I cannot check if the plugin works or more is missing.
read the helpfile and double check everything to see if its correct. -
Yes, I double-checked and even re-typed the curly brackets in that file, but to no avail - it still refuses to load.
-
That file does haveis in the "en" folder which has no { and } on battle.json.
{and}surrounding it - perhaps your horizontal zoom was a little bit to the right so you couldn't see them?
As to @Jacie0krece 's the error: "unexpected token u at position 0" sounds suspiciously like trying to parse "undefined".
What's the deal with that missing css/game.css file? Do you have a file like this? Do you know which plugin is trying to load it? If loading it fails, it might break things with loading subsequent files as well.
Are you perhaps using git? If so, have your tried doing a diff between the current version and the last working commit?drop at least a commit today
EDIT: Mentioned the wrong person somehow, sorry about that. -
When it comes to the diffs, GitHub Desktop doesn't show me anything out of the ordinary, excluding VS adding a space between the key and the value, changing the characters between sets of keys from what appear to be tabs into spaces, and adding some random files of its own in .vs subfolders - but these three would be pretty bad reasons for it to completely refuse to load. Also, I don't have a css/game.css file or even the css/ folder at all - and the plugin that makes the game refuse to load is definitely ODW_MultiLanguageSystem (I disabled it and the game ran), unless it's a ferocious combo of this and another plugin. Just in case, here's my plugin list:
-
So, what else changed? I don't think VS formatting would actually break anything, so it's probably something else you've done in the meantime that you either forgot about or decided it's not important enough to mention. The most likely culprit would be either plugin configuration, or something related to the config manager being in an invalid state.When it comes to the diffs, GitHub Desktop doesn't show me anything out of the ordinary, excluding VS adding a space between the key and the value, changing the characters between sets of keys from what appear to be tabs into spaces, and adding some random files of its own in .vs subfolders - but these three would be pretty bad reasons for it to completely refuse to load. Also, I don't have a css/game.css file or even the css/ folder at all - and the plugin that makes the game refuse to load is definitely ODW_MultiLanguageSystem (I disabled it and the game ran), unless it's a ferocious combo of this and another plugin. Just in case, here's my plugin list:
View attachment 283104
If the latter, maybe try deleting the config save? It should hopefully get recreated correctly. -
Hi @Jacie0krece. At the moment, I can't help you more than to ask you to purge your save folder and test your game again. It looks like you're loading an undefined "language" from the plugin settings (see line 521 here). Purging your save folder will reset the game to the default language. If the game doesn't work after that, I suggest you check the plugins.js file for corruption. And definitely, the problem comes before the JSON files are loaded.
For other people, thanks for helping to solve this problem with my plugin. Your help is appreciated. -
I deleted the entirety of the "save" folder, including that folder itself, and it didn't help. How can I check if my plugins.js file is corrupted, and how do I fix it if it is?
-
If your game launches, the formatting in that file is probably fine, but there might be problems with the plugin options. Try removing the plugin via Plugin Manager, then adding it back and setting all the options again.I deleted the entirety of the "save" folder, including that folder itself, and it didn't help. How can I check if my plugins.js file is corrupted, and how do I fix it if it is?
-
Sadly, the error still doesn't wanna go away, even if I removed the plugin and then added it. But, what I noticed is that with the "Languages" option empty, the game actually runs - however, if I add a language, even without modifying the options of that language (which confirms that my .json files aren't a problem, as the default option's folder is "languages/eng", while I have "languages/en"), the error reappears.