Skript

Skript

743k Downloads

"Parse if" section/condition

Palgia opened this issue ยท 1 comments

commented

Suggestion

Add a "parse if" section that would tell Skript whether the code below should be read or not if a condition is met.

Example:

command /test:
	trigger:
		parse if script "main" is loaded:
			broadcast "this can be parsed!"
			stop
		broadcast "you need to load main skript!"

Why?

This condition would make sharing Skripts easier without the need to create multiple different versions depending on the APIs/Plugins/Other skripts used. For example, if I want to use functions from several skripts that I consider optional, I'd like to be able to tell Skript to ignore certain pieces of my code if they are not installed. For those who share resources on skUnity (like me), this would be really useful.

Other

No response

Agreement

  • I have read the guidelines above and affirm I am following them with this suggestion.
commented

That's already a thing