8000 compatibility with other mods (mainly pipeworks) by mazes-80 · Pull Request #10 · joe7575/lumberjack · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

compatibility with other mods (mainly pipeworks) #10

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

Merged
merged 1 commit into from
Mar 29, 2021
Merged

compatibility with other mods (mainly pipeworks) #10

merged 1 commit into from
Mar 29, 2021

Conversation

mazes-80
Copy link
Contributor

2021-03-28 14:01:09: ERROR[Main]: ServerError: AsyncErr: environment_Step: Runtime error from mod '' in callback environment_Step(): /home/sam/.minetest/mods/lumberjack/init.lua:128: attempt to call method 'get_meta' (a nil value)

nodebreaker don't have a get_meta function so the mod lumberjack crashes the server.
the workaround I propose always give the old lumberjack "priv" to the nodebreaker (is_lumberjack returns -1,-1)

also this pr fixes diamond axe case where cap.choppy = 3, the old test was < 3, new is <=3

@joe7575 joe7575 merged commit d74cc0e into joe7575:master Mar 29, 2021
@mazes-80
Copy link
Contributor Author

I didn't figure out a way to access real player metadata, the idea pleases me as it would allow nodebreakers to take in account the "lumberjack privilege", or to add a setting on the way non real players behavior.
The way I did it seems to me more like a workaround who avoid crashes.
I'll try to find a way, but if you already see how to it, it may avoid me a bit pain, then I'll read and learn.

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 this pull request may close these issues.

2 participants
0