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

Condition enhancements #6809

Closed
1 task done
MissingReports opened this issue Jun 22, 2024 · 1 comment
Closed
1 task done

Condition enhancements #6809

MissingReports opened this issue Jun 22, 2024 · 1 comment
Labels
duplicate For bugs or requests that have already been made and are currently open.

Comments

@MissingReports
Copy link

Suggestion

First, I feel like making conditions act like expressions would be nice, for example set {_isSet} to {variable} is set
This is most useful is functions where you would want to do something like this

function hasDiamond(p: player) :: boolean:
    return {_p} has diamond

instead of

function hasDiamond(p: player) :: boolean:
    if {_p} has diamond:
        return true
    return false

i know this is abit lazy but it also cleans the code abit. and doesn't cause confusion for people that use skript and java

Second, i don't even know why this isn't a thing but you can't do if true, you have to do if true is true which also causes confusion when using skript and java

Why?

Cleaning up code and makes skript similar to pretty much all scripting languages

Other

No response

Agreement

  • I have read the guidelines above and affirm I am following them with this suggestion.
@sovdeeth
Copy link
Member

See #6748

@sovdeeth sovdeeth added the duplicate For bugs or requests that have already been made and are currently open. label Jun 22, 2024
@sovdeeth sovdeeth closed this as not planned Won't fix, can't repro, duplicate, stale Jun 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate For bugs or requests that have already been made and are currently open.
Projects
None yet
Development

No branches or pull requests

2 participants