1
0
의 미러 https://github.com/sys4-fr/server-nalc.git synced 2025-12-21 17:15:32 +01:00

Added triple registrering of runes

- Runes are registered three times with tree levels : minor, medium, major
This commit is contained in:
LeMagnesium
2015-04-27 13:57:15 +02:00
부모 0e2de4f1be
커밋 39e46b06b4
4개의 변경된 파일7개의 추가작업 그리고 8개의 파일을 삭제

Binary file not shown.

Before

Width:  |  Height:  |  크기: 2.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  크기: 3.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  크기: 2.8 KiB

파일 보기

@@ -91,14 +91,13 @@ minetest.register_globalstep(function(dtime)
end end
for key, value in pairs(mana_from_node) do for key, value in pairs(mana_from_node) do
if key:split(":")[1] == "group" then if key:split(":")[1] == "group" then
local groupname = key:split(":")[2] local groupname = key:split(":")[2]
if minetest.get_node_group(node.name, groupname) > 0 then if minetest.get_node_group(node.name, groupname) > 0 then
regen_to = math.max(regen_to, value) -- We get the greater one (if the node is part of 2 or more groups) regen_to = math.max(regen_to, value) -- We get the greater one (if the node is part of 2 or more groups)
end end
end end
end end
mana.setregen(name, regen_to) mana.setregen(name, regen_to)
--print("Regen to "..regen_to.." : "..light_day.."/"..light_now.."/"..light_night) --print("Regen to "..regen_to.." : "..light_day.."/"..light_now.."/"..light_night)