From b0cb1d325a61bae42cbe932ff1b0b22aa8222af6 Mon Sep 17 00:00:00 2001 From: Hugo Locurcio Date: Mon, 25 Feb 2019 10:47:51 +0100 Subject: [PATCH] Fix Stairs+ node rotation on placement This closes #123. --- CHANGELOG.md | 4 ++++ stairsplus/common.lua | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 53c4458..2ead1d5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ## [Unreleased] +### Fixed + +- Node rotation now works correctly when placing Stairs+ nodes. + ## [1.2.0] - 2018-11-24 ### Added diff --git a/stairsplus/common.lua b/stairsplus/common.lua index a383935..e4d0017 100644 --- a/stairsplus/common.lua +++ b/stairsplus/common.lua @@ -30,6 +30,10 @@ stairsplus.register_single = function(category, alternate, info, modname, subnam end def.paramtype = "light" def.paramtype2 = def.paramtype2 or "facedir" + + -- This makes node rotation work on placement + def.place_param2 = nil + def.on_place = minetest.rotate_node if category ~= "slab" then def.description = S("%s " .. descriptions[category]):format(fields.description)