Add files via upload

master
Jared Landers 2019-05-30 22:06:56 -07:00 committed by GitHub
parent c32f6a296d
commit e3e5eb65ff
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 8 deletions

View File

@ -9,12 +9,7 @@ local mul_3dx2 = function(a,b)
end
multiplacer.activate = function(player, material, pointed_thing, mode)
if minetest.get_item_group(material, "liquid") > 0 then
return nil;
end
-- if minetest.get_draw_type(material, "liquid") then
-- return nil;
-- end
if( player == nil or pointed_thing == nil) then
return nil;
end
@ -28,6 +23,10 @@ multiplacer.activate = function(player, material, pointed_thing, mode)
if not material then
return nil;
end
-- minetest.chat_send_player( player:get_player_name(), dump(minetest.get_item_group(material, "liquid")));
if minetest.get_item_group(material, "liquid") > 0 then
return nil;
end
local x = stack:get_count()
local y = inv:get_stack("main", 2):get_count()
local z = inv:get_stack("main", 3):get_count()
@ -35,8 +34,7 @@ multiplacer.activate = function(player, material, pointed_thing, mode)
return nil;
end
local look_dir = player:get_look_dir()
local dir = {x=look_dir.x/math.abs(look_dir.x), y=1, z=look_dir.z/math.abs(look_dir.z)}
-- minetest.chat_send_player( player:get_player_name(), " " .. material);
local dir = {x=look_dir.x/math.abs(look_dir.x), y=look_dir.y/math.abs(look_dir.y), z=look_dir.z/math.abs(look_dir.z)}
for ix = 0, x-1 do
for iy = 0, y-1 do
for iz = 0, z-1 do