Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
- Code: Select all
minetest.register_node("default:rail", {
description = "Rail",
drawtype = "raillike",
tiles = {"default_rail.png", "default_rail_curved.png", "default_rail_t_junction.png", "default_rail_crossing.png"},
inventory_image = "default_rail.png",
wield_image = "default_rail.png",
paramtype = "light",
paramtype2 = "wallmounted",
is_ground_content = true,
walkable = false,
selection_box = {
type = "fixed",
-- but how to specify the dimensions for curved and sideways rails?
fixed = {-1/2, -1/2, -1/2, 1/2, -1/2+1/16, 1/2},
},
groups = {bendy=2,snappy=1,dig_immediate=2,attached_node=1},
})
It's (obviously) the default:rail registry. With paramtype2 = "wallmounted" added. I know I'm wrong but in all logic that means that sh*t can go on a wall! Lol. Ever since I found the "carts" mod, I have want to stick the rail on the wall to make elevators. It would be PERFECT for mesecons. I'm starting to realize that can't be done.
P.S. I did change it from default:rail to elevator:shaft. In case you thought that would be a problem.