diff --git a/mods/ctf/ctf_classes/medic.lua b/mods/ctf/ctf_classes/medic.lua index 7a198a5..7115c39 100644 --- a/mods/ctf/ctf_classes/medic.lua +++ b/mods/ctf/ctf_classes/medic.lua @@ -138,7 +138,7 @@ minetest.override_item("ctf_bandages:bandage", { local diggers = {} local DIG_COOLDOWN = 30 -local DIG_DIST_LIMIT = 50 +local DIG_DIST_LIMIT = 30 local DIG_SPEED = 0.1 local function isdiggable(name) diff --git a/mods/ctf/ctf_classes/melee.lua b/mods/ctf/ctf_classes/melee.lua index 8cd894c..b1d176a 100644 --- a/mods/ctf/ctf_classes/melee.lua +++ b/mods/ctf/ctf_classes/melee.lua @@ -49,7 +49,7 @@ minetest.register_tool("ctf_classes:sword_bronze", { groupcaps={ snappy={times={[1]=2.5, [2]=1.20, [3]=0.35}, uses=0, maxlevel=2}, }, - damage_groups = {fleshy=6, sword=1}, + damage_groups = {fleshy=6}, punch_attack_uses = 0, }, sound = {breaks = "default_tool_breaks"}, diff --git a/mods/ctf/ctf_events/init.lua b/mods/ctf/ctf_events/init.lua index 18bf340..f321831 100644 --- a/mods/ctf/ctf_events/init.lua +++ b/mods/ctf/ctf_events/init.lua @@ -124,7 +124,7 @@ ctf.register_on_killedplayer(function(victim, killer, stack, tool_caps) local victim_color = ctf_colors.get_color(ctf.player(victim)) local killer_color = ctf_colors.get_color(ctf.player(killer)) - local type = "sword" -- Also used for unknown attacks + local type = "sword" if tool_caps.damage_groups.grenade then type = "grenade" diff --git a/mods/ctf/ctf_events/textures/ctf_events_kill_unknown.png b/mods/ctf/ctf_events/textures/ctf_events_kill_unknown.png deleted file mode 100644 index a2c5bcc..0000000 Binary files a/mods/ctf/ctf_events/textures/ctf_events_kill_unknown.png and /dev/null differ diff --git a/mods/ctf/ctf_respawn_delay/init.lua b/mods/ctf/ctf_respawn_delay/init.lua index ab3b481..8c73974 100644 --- a/mods/ctf/ctf_respawn_delay/init.lua +++ b/mods/ctf/ctf_respawn_delay/init.lua @@ -8,7 +8,8 @@ local RESPAWN_MESSAGE = "Respawning in " minetest.register_on_dieplayer(function(player, reason) local pname = player:get_player_name() - if ctf_match.is_in_build_time() or ctf_respawn_delay.players[pname] then -- what is dead may never die + if ctf_match.is_in_build_time() or (reason.type == "punch" and reason.object and + reason.object:is_player() and reason.object:get_player_name() == pname) then return end diff --git a/mods/ctf/ctf_traps/init.lua b/mods/ctf/ctf_traps/init.lua index c65897e..db2f2a2 100644 --- a/mods/ctf/ctf_traps/init.lua +++ b/mods/ctf/ctf_traps/init.lua @@ -63,10 +63,7 @@ minetest.register_node("ctf_traps:damage_cobble", { if placerobj then digger:punch(placerobj, 10, {damage_groups = {fleshy = 7}}, vector.new(0, 1, 0)) else - local hp = digger:get_hp() - if hp > 0 then - digger:set_hp(hp - 7) - end + digger:set_hp(digger:get_hp() - 7) end minetest.remove_node(pos) diff --git a/mods/mtg/default/tools.lua b/mods/mtg/default/tools.lua index 2bc313c..e28cd19 100644 --- a/mods/mtg/default/tools.lua +++ b/mods/mtg/default/tools.lua @@ -257,7 +257,7 @@ minetest.register_tool("default:sword_stone", { groupcaps={ snappy={times={[2]=1.4, [3]=0.40}, uses=20, maxlevel=1}, }, - damage_groups = {fleshy=4, sword=1}, + damage_groups = {fleshy=4}, }, sound = {breaks = "default_tool_breaks"}, }) @@ -271,7 +271,7 @@ minetest.register_tool("default:sword_bronze", { groupcaps={ snappy={times={[1]=2.75, [2]=1.30, [3]=0.375}, uses=25, maxlevel=2}, }, - damage_groups = {fleshy=6, sword=1}, + damage_groups = {fleshy=6}, }, sound = {breaks = "default_tool_breaks"}, }) @@ -285,7 +285,7 @@ minetest.register_tool("default:sword_steel", { groupcaps={ snappy={times={[1]=2.5, [2]=1.20, [3]=0.35}, uses=30, maxlevel=2}, }, - damage_groups = {fleshy=6, sword=1}, + damage_groups = {fleshy=6}, }, sound = {breaks = "default_tool_breaks"}, }) @@ -299,7 +299,7 @@ minetest.register_tool("default:sword_mese", { groupcaps={ snappy={times={[1]=2.0, [2]=1.00, [3]=0.35}, uses=30, maxlevel=3}, }, - damage_groups = {fleshy=7, sword=1}, + damage_groups = {fleshy=7}, }, sound = {breaks = "default_tool_breaks"}, }) @@ -313,7 +313,7 @@ minetest.register_tool("default:sword_diamond", { groupcaps={ snappy={times={[1]=1.90, [2]=0.90, [3]=0.30}, uses=40, maxlevel=3}, }, - damage_groups = {fleshy=8, sword=1}, + damage_groups = {fleshy=8}, }, sound = {breaks = "default_tool_breaks"}, })