-
Notifications
You must be signed in to change notification settings - Fork 11
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
- there's now a command that lets players choose the colour of the XP… #47
Conversation
… bar and text - the HUD rank-icon is configurable - dead players lose not 1000 XP, but only 10% of the next rank - when a player dies, he is shown how much XP he lost - players cannot lose levels when they die, only XP - there's a servermessage now on levelup - the hud now shows the XP to the next level and the XP a player is already in on that level. Also the XP sum in []
end | ||
level_up(player, currentRank) | ||
local text = "Congratulations, "..playername.." reached "..currentRank.name | ||
minetest.chat_send_all(minetest.colorize("#98ff98",text)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be configurable, that is allow disabling global messages.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Most of the other stuff should also be configurable, right?
I mean, not everyone wants players to lose a fixed 1000 XP as it is now, but maybe I should make that configurable too. Maybe even the fixed amount or the % of the next level that gets lost on death. depending on the level formula, 10% of the next level might be much more than those 1000 XP.
Same goes for not losing levels. I need that for my game. But someone else's game may depend on people losing levels.
The message also needs to be translatable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Most of the other stuff should also be configurable, right?
Yes of course it would be nice but I don't think that belongs to this pull request.
not everyone wants players to lose a fixed 1000 XP as it is now, but maybe I should make that configurable too.
That would be nice too, keep that 1000 as default and add configuration option, however again not that important for this PR.
The message also needs to be translatable.
That would be nice, actual translations of course can be added later too. Actually I have no idea how translations work in chat messages... if client side translation even works there. If it does not then it gets bit complicated.
Only thing I see as important so far for this exact PR before merging would be option to disable chat message, later I could also see good configuration option to partially disable as in only send level up messages to everyone if player has say > 20k XP.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually seems that I did misread whole thing, yes XP reduction type should be configurable and possibly overrideable, select from few basic: default -1000 or optionally percentage. There could be 2 config options: type and amount. Keep current behavior as default.
Override can be then used to ignore config and implement complex custom function outside of mod if needed.
Ranks, not sure how important this is. It might be but I suppose most would track XP amount but could be wrong...
… bar and text
Solves #29
Helps #44