aboutsummaryrefslogtreecommitdiff
path: root/assets/mbbrailtextures
Commit message (Collapse)AuthorAge
* Download recent contributions and put them into the assets directoryorwell962017-01-17
'>24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94
-- Ks Signals for advtrains
-- will implement the advtrains signal API (which does not exist yet)

local function place_degrotate(pos, placer, itemstack, pointed_thing)
	local yaw = placer:get_look_horizontal()
	local param = math.floor(yaw * 90 / math.pi + 0.5)
	local n = minetest.get_node(pos)
	n.param2 = param
	minetest.set_node(pos, n)
end

minetest.register_node("advtrains_signals_ks:mast", {
	drawtype = "mesh",
	paramtype="light",
	paramtype2="degrotate",
	walkable = false,
	selection_box = {
		type = "fixed",
		fixed = {-1/4, -1/2, -1/4, 1/4, 1/2, 1/4},
	},
	mesh = "advtrains_signals_ks_mast.obj",