Add gitignore

This commit is contained in:
kilbith 2016-01-06 14:40:42 +01:00
parent b9ef47f24f
commit 00dd4c6a66
4 changed files with 23 additions and 11 deletions

7
.gitignore vendored Normal file
View File

@ -0,0 +1,7 @@
## Generic ignorable patterns and files
*~
.*.swp
*bak*
tags
*.vim

View File

@ -1,7 +1,10 @@
Code : GPLv3 ------------------------------------------------------------------------
Textures : WTFPL (credits: Gambit, Cisoun, kilbith) | Copyright (c) 2015-2016 kilbith <jeanpatrick.guerrero@gmail.com> |
| |
| Code: GPL version 3 |
| Textures: WTFPL (credits: Gambit, kilbith, Cisoun) |
------------------------------------------------------------------------
==============================================================
GNU GENERAL PUBLIC LICENSE GNU GENERAL PUBLIC LICENSE
Version 3, 29 June 2007 Version 3, 29 June 2007

View File

@ -1,12 +1,14 @@
## X-Decor ## ## X-Decor ##
##### Minimal decoration mod for Minetest meant to be light and simple. ##### ##### A decoration mod meant to be light, simple and well-featured. #####
##### It adds just the essential made of cute pixels and cubes. ##### ##### It adds a bunch of cute cubes and stuff for cutting, cooking, enchanting, etc. #####
##### It's a lightweight alternative to homedecor and moreblocks all together. ##### ##### It's a lightweight alternative to Home Decor and More Blocks all together. #####
### Credits ### ### Credits ###
##### Special thanks to Gambit for the textures from PixelBox ##### ##### Special thanks to Gambit for the textures from the PixelBOX pack for Minetest. #####
![Preview](http://i.imgur.com/VorR6zc.png) ![Preview](http://i.imgur.com/VorR6zc.png)
![Preview2](http://i.imgur.com/M05BqjT.png) ![Preview2](http://i.imgur.com/M05BqjT.png)
![Preview3](https://lut.im/oWfKNfxAA4/n9jqwFpJOdUdo8yT.png)
![Preview4](https://lut.im/BBG10S4T2x/VNRPd7gK9bTMYSST.png)

View File

@ -334,7 +334,7 @@ function worktable.move(pos, from_list, from_index, to_list, to_index, count, _)
return 0 return 0
end end
function worktable.update_inventory(inv, inputstack) function worktable.get_output(inv, inputstack)
if inv:is_empty("input") then if inv:is_empty("input") then
inv:set_list("forms", {}) inv:set_list("forms", {})
return return
@ -354,7 +354,7 @@ end
function worktable.on_put(pos, listname, _, stack, _) function worktable.on_put(pos, listname, _, stack, _)
if listname == "input" then if listname == "input" then
local inv = minetest.get_meta(pos):get_inventory() local inv = minetest.get_meta(pos):get_inventory()
worktable.update_inventory(inv, stack) worktable.get_output(inv, stack)
end end
end end
@ -362,7 +362,7 @@ function worktable.on_take(pos, listname, index, stack, _)
local inv = minetest.get_meta(pos):get_inventory() local inv = minetest.get_meta(pos):get_inventory()
if listname == "input" then if listname == "input" then
if stack:get_name() == inv:get_stack("input", 1):get_name() then if stack:get_name() == inv:get_stack("input", 1):get_name() then
worktable.update_inventory(inv, stack) worktable.get_output(inv, stack)
else else
inv:set_list("forms", {}) inv:set_list("forms", {})
end end
@ -370,7 +370,7 @@ function worktable.on_take(pos, listname, index, stack, _)
local inputstack = inv:get_stack("input", 1) local inputstack = inv:get_stack("input", 1)
inputstack:take_item(math.ceil(stack:get_count() / def[index][2])) inputstack:take_item(math.ceil(stack:get_count() / def[index][2]))
inv:set_stack("input", 1, inputstack) inv:set_stack("input", 1, inputstack)
worktable.update_inventory(inv, inputstack) worktable.get_output(inv, inputstack)
end end
end end