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

[Bug] - Extension alters workspace.settings.json with incorrect settings #340

Open
Tristimdorion opened this issue Jun 12, 2023 · 7 comments · Fixed by #344
Open

[Bug] - Extension alters workspace.settings.json with incorrect settings #340

Tristimdorion opened this issue Jun 12, 2023 · 7 comments · Fixed by #344

Comments

@Tristimdorion
Copy link

When installing the latest pre-release the workspace settings for 'Colors' create faulty settings with garbled data.

@duckdoom4
Copy link
Collaborator

Hi there, thanks for the bug report. Could you include a sample of the invalid data?

@duckdoom4
Copy link
Collaborator

Please try v2.3.4, this issue is likely fixed in that build :)

@Tristimdorion
Copy link
Author

Can confirm issue is resolved with v2.3.4

@Tristimdorion
Copy link
Author

Tristimdorion commented Jun 14, 2023

Unfortunately, it is back, here is an overview of the faulty settings in my workspace and I think it is related to this line in my renpy code:

menu:
"Light Distraction\n{color=ff0000}{size=18}[distraction_percentages[0]]%% Chance{/size}{/color}"

Hope this helps:

			{
				"scope": "renpy.meta.color.#ffff00",
				"settings": {
					"foreground": "#ffff00"
				}
			},
			{
				"scope": "renpy.meta.color.ff0000",
				"settings": {
					"foreground": "ff0000"
				}
			},
			{
				"scope": "renpy.meta.color.ff0000}{size=18}[distraction_percentages[2]]%% chance{/size}{/color}\":",
				"settings": {
					"foreground": "ff0000}{size=18}[distraction_percentages[2]]%% chance{/size}{/color}\":"
				}
			},
			{
				"scope": "renpy.meta.color.ff0000}{size=18}[distraction_percentages[1]]%% chance{/size}{/color}\":",
				"settings": {
					"foreground": "ff0000}{size=18}[distraction_percentages[1]]%% chance{/size}{/color}\":"
				}
			},
			{
				"scope": "renpy.meta.color.ff0000}{size=18}[distraction_percentages[0]]%% chance{/size}{/color}\":",
				"settings": {
					"foreground": "ff0000}{size=18}[distraction_percentages[0]]%% chance{/size}{/color}\":"
				}
			}

@LuqueDaniel LuqueDaniel reopened this Jun 14, 2023
@duckdoom4
Copy link
Collaborator

duckdoom4 commented Jun 14, 2023

Okay, so I resolved this issue however I'm a little surprised.
The issue is that {color=ff0000} doesn't contain a #. According to the renpy documentation this is invalid syntax. Does it actually compile and work as intended?
If it does work I may need to resolve this in a different way.

@duckdoom4 duckdoom4 linked a pull request Jun 14, 2023 that will close this issue
@Tristimdorion
Copy link
Author

It really does work, it just renders as if the # was there.

@duckdoom4
Copy link
Collaborator

Hm, okay. In that case I'll have to add support for that

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 a pull request may close this issue.

3 participants