Skip to content

Commit

Permalink
Register travelnet nodes as MVPS stoppers (#93)
Browse files Browse the repository at this point in the history
  • Loading branch information
Niklp09 authored Dec 10, 2024
1 parent 193773b commit e6c9a28
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 1 deletion.
4 changes: 4 additions & 0 deletions elevator.lua
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,10 @@ minetest.register_node("travelnet:elevator", {
end
})

if minetest.get_modpath("mesecons_mvps") then
mesecon.register_mvps_stopper("travelnet:elevator")
end

minetest.register_craft({
output = "travelnet:elevator",
recipe = travelnet.elevator_recipe,
Expand Down
3 changes: 3 additions & 0 deletions init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,9 @@ minetest.register_node("travelnet:hidden_top", {
drop = "",
})

if minetest.get_modpath("mesecons_mvps") then
mesecon.register_mvps_stopper("travelnet:hidden_top")
end

if travelnet.travelnet_effect_enabled then
minetest.register_entity("travelnet:effect", {
Expand Down
2 changes: 1 addition & 1 deletion mod.conf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name = travelnet
depends = xcompat
optional_depends = mesecons, mtt
optional_depends = mesecons, mesecons_mvps, mtt
description = Network of teleporter-boxes that allows easy travelling to other boxes on the same network.
4 changes: 4 additions & 0 deletions register_travelnet.lua
Original file line number Diff line number Diff line change
Expand Up @@ -127,4 +127,8 @@ function travelnet.register_travelnet_box(cfg)
recipe = { "group:travelnet", cfg.dye },
})
end

if minetest.get_modpath("mesecons_mvps") then
mesecon.register_mvps_stopper(cfg.nodename)
end
end

0 comments on commit e6c9a28

Please sign in to comment.