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

Beware the Dark Not Working Properly on Servers #2

Open
lumidify opened this issue Aug 19, 2016 · 3 comments
Open

Beware the Dark Not Working Properly on Servers #2

lumidify opened this issue Aug 19, 2016 · 3 comments

Comments

@lumidify
Copy link

lumidify commented Aug 19, 2016

When I play this on a server, sanity works, but I only get the actual hud element shown the first time I join (until the server is restarted). It seems as if this is because of lines 67-71 in init.lua:

if not pl then
        M.players[name] = { pending_dmg = 0.0 }
        pl = M.players[name]
        M.hud_init(player)
end

The way I understand this is that M.hud_init, which actually shows the hud element to the player, is only shown the first time they join, until the server is restarted (and M.players is emptied). However, it works if I move M.Hud_init(player) out of the if statement, like so:

if not pl then
        M.players[name] = { pending_dmg = 0.0 }
        pl = M.players[name]
end
M.hud_init(player)

Am I missing something, or why is M.hud_init only run the first time the player joins?

@lumidify lumidify changed the title Not working properly on server Beware the Dark Not Working Properly on Servers Aug 19, 2016
@minertestdude
Copy link

@lumidify Hello. I have implemented your change in my fork. I will do pull request into this branch, but it looks unlikely that this branch will be updated. @bendeutsch or perhaps not hope is lost? :-)

@lumidify
Copy link
Author

@minertestdude Hi, I'm glad to know this was still useful for someone - I'd completely forgotten about it over the years...

@bendeutsch
Copy link
Owner

Hello everyone, I'm sorry, but I don't have the time to work on anything Minetest-related right now. A fork actually sounds like the best option. I'm glad it seems someone is keeping this going!

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

No branches or pull requests

3 participants