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

Make //lua work with expressions as well #243

Merged
merged 11 commits into from
Apr 20, 2024
Merged

Make //lua work with expressions as well #243

merged 11 commits into from
Apr 20, 2024

Conversation

imre84
Copy link
Contributor

@imre84 imre84 commented Mar 25, 2024

Hello,

so with this patch you can do something like //lua return minetest.get_node_light(p.pos) I think this is a useful development helper tool for mod developers, maybe it can save you 1-2 server restarts. Also it is backwards compatible: every //lua command that used to work will still work

Copy link
Collaborator

@sfan5 sfan5 left a comment

Choose a reason for hiding this comment

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

Another idea:

  • support the = syntax as a shorthand for writing return before the statement

worldedit/code.lua Outdated Show resolved Hide resolved
worldedit/code.lua Outdated Show resolved Hide resolved
worldedit/code.lua Outdated Show resolved Hide resolved
worldedit_commands/init.lua Outdated Show resolved Hide resolved
@sfan5 sfan5 changed the title make //lua work with expressions as well Make //lua work with expressions as well Mar 26, 2024
imre84 added a commit to imre84/Minetest-WorldEdit that referenced this pull request Mar 28, 2024
imre84 added a commit to imre84/Minetest-WorldEdit that referenced this pull request Mar 28, 2024
@imre84
Copy link
Contributor Author

imre84 commented Apr 19, 2024

hello, ok so do I need to do anything more to make this PR accepted/merged?

@sfan5
Copy link
Collaborator

sfan5 commented Apr 19, 2024

I'm quite short on time, so you just have to wait.

@sfan5 sfan5 merged commit 883caff into Uberi:master Apr 20, 2024
3 checks passed
@sfan5
Copy link
Collaborator

sfan5 commented Apr 20, 2024

Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants