diff options
author | Andrey K <NaruTrey@users.noreply.github.com> | 2016-06-09 23:06:39 +0400 |
---|---|---|
committer | Andrey K <NaruTrey@users.noreply.github.com> | 2016-06-09 23:06:39 +0400 |
commit | f7cf9d773c16f8f7ade37dc308a96c4d14bf0f16 (patch) | |
tree | a2a44fce26ac028a5dcf962733c470e5e794edbe /trackplacer.lua | |
parent | 40f3f2eb5d7ff873c613e06c145a4811e9465bf0 (diff) | |
download | advtrains-f7cf9d773c16f8f7ade37dc308a96c4d14bf0f16.tar.gz advtrains-f7cf9d773c16f8f7ade37dc308a96c4d14bf0f16.tar.bz2 advtrains-f7cf9d773c16f8f7ade37dc308a96c4d14bf0f16.zip |
Unlimited rails in creative mode
Diffstat (limited to 'trackplacer.lua')
-rw-r--r-- | trackplacer.lua | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/trackplacer.lua b/trackplacer.lua index 68c1c7c..b1e57a5 100644 --- a/trackplacer.lua +++ b/trackplacer.lua @@ -122,7 +122,9 @@ function advtrains.register_track_placer(nnprefix, imgprefix, dispname) local pos=pointed_thing.above if minetest.registered_nodes[minetest.get_node(pos).name] and minetest.registered_nodes[minetest.get_node(pos).name].buildable_to then advtrains.placetrack(pos, nnprefix) - itemstack:take_item() + if not minetest.setting_getbool("creative_mode") then + itemstack:take_item() + end end end return itemstack @@ -197,4 +199,4 @@ minetest.register_craftitem("advtrains:trackworker",{ end end end, -})
\ No newline at end of file +}) |