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 aliases parsing #3839

Merged

Conversation

TPGamesNL
Copy link
Member

Description

Fix parsing of items with json with commas. Test script:

aliases:
	test_item1 = minecraft:stick {display:{Name:'{"text":"test_name","italic":false}'}}
	test_item2 = minecraft:stick {display:{Lore:['[{"text":"test_lore"}]']}}
	test_item3 = minecraft:stick {display:{Name:'{"text":"test_name","italic":false}',Lore:['[{"text":"test_lore"}]']}}
	test_item4 = minecraft:stick {display:{Name:'{"text":"test_name","italic":false}',Lore:['[{"text":"test_lore"}]']}}, minecraft:stick {display:{Name:'{"text":"other namE","italic":false}',Lore:['[{"text":"tttt"}]']}}

command /test:
	trigger:
		set {_item1} to test_item1
		message "%{_item1}%"
		set {_item2} to test_item2
		message "%{_item2}%"
		set {_item3} to test_item3
		message "%{_item3}%"
		message "%lore of {_item3}%"
		set {_item4} to test_item4
		message "%{_item4}%"

Target Minecraft Versions: any
Requirements: none
Related Issues: #3776

@TPGamesNL TPGamesNL added 2.5 bug An issue that needs to be fixed. Alternatively, a PR fixing an issue. labels Mar 21, 2021
Copy link
Member

@APickledWalrus APickledWalrus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@APickledWalrus APickledWalrus merged commit 8ffab27 into SkriptLang:master May 9, 2021
@TPGamesNL TPGamesNL deleted the fix/aliases-comma-parsing branch May 10, 2021 07:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An issue that needs to be fixed. Alternatively, a PR fixing an issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants