Skip to content

Commit

Permalink
Merge branch 'master' into barrier-commands
Browse files Browse the repository at this point in the history
  • Loading branch information
a-blob authored Jun 17, 2024
2 parents 38ffb39 + e5c4f92 commit dea5561
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 6 deletions.
2 changes: 1 addition & 1 deletion mods/ctf/ctf_map/maps
12 changes: 8 additions & 4 deletions mods/ctf/ctf_modebase/ranking_commands.lua
Original file line number Diff line number Diff line change
Expand Up @@ -206,10 +206,14 @@ minetest.register_chatcommand("reset_rankings", {
allow_reset[key] = nil
end)

return true, "This will reset your stats and rankings for " .. mode_name .." mode completely."
.. " You will lose access to any special privileges such as the"
.. " team chest or userlimit skip. This is irreversable. If you're"
.. " sure, re-type /reset_rankings within 30 seconds to reset."
return true, minetest.colorize("red", "This will reset your (") ..
minetest.colorize("cyan", name) ..
minetest.colorize("red", ") stats and rankings for ") ..
minetest.colorize("cyan", mode_name) ..
minetest.colorize("red", " mode completely.\n") ..
"You will lose access to any special privileges such as the " ..
"team chest or userlimit skip. This is irreversable. If you're " ..
"sure, re-type /reset_rankings within 30 seconds to reset."
end
mode_data.rankings:set(name, {}, true)
allow_reset[key] = nil
Expand Down
4 changes: 3 additions & 1 deletion mods/ctf/ctf_teams/team_chest.lua
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,9 @@ for _, team in ipairs(ctf_teams.teamlist) do
end
meta:set_string("dropped_by", "")
local inv = minetest.get_inventory({ type="node", pos=pos })
inv:set_stack(listname, index, stack)
local stack_ = inv:get_stack(listname,index)
stack_:get_meta():set_string("dropped_by", "")
inv:set_stack(listname, index, stack_)
end

function def.on_metadata_inventory_take(pos, listname, index, stack, player)
Expand Down

0 comments on commit dea5561

Please sign in to comment.