more improvements

master
D00Med 2017-02-03 17:07:00 +10:00
parent 2fbf11c930
commit e274b3e0fd
6 changed files with 28 additions and 7 deletions

View File

@ -218,7 +218,8 @@ function vehicles.object_drive(entity, dtime, def)
minetest.set_node(pos, {name=place_node})
end
if place_trigger ~= nil and ctrl.sneak then
minetest.set_node(pos, {name=place_node})
local facedir = minetest.dir_to_facedir(dir)
minetest.set_node(pos, {name=place_node, param2=facedir})
end
end

View File

@ -2366,18 +2366,28 @@ minetest.register_node("vehicles:tyres", {
minetest.register_node("vehicles:light_barrier", {
description = S("Light Barrier"),
tiles = {"vehicles_lightblock.png",},
tiles = {
"vehicles_lightblock.png^[transformR90",
"vehicles_lightblock.png^[transformR90",
"vehicles_lightblock.png",
},
use_texture_alpha = true,
drawtype = "allfaces",
drawtype = "nodebox",
paramtype = "light",
paramtype2 = "facedir",
node_box = {
type = "fixed",
fixed = {
{-0.0625, -0.5, -0.5, 0.0625, 0.5, 0.5},
}
},
sunlight_propagates = true,
walkable = false,
light_source = 9,
is_ground_content = true,
groups = {cracky=3,dig_immediate=3,not_in_creative_inventory=1},
on_construct = function(pos, node)
minetest.get_node_timer(pos):start(4)
return
end,
on_timer = function(pos, elapsed)
minetest.remove_node(pos)
@ -2386,18 +2396,28 @@ minetest.register_node("vehicles:light_barrier", {
minetest.register_node("vehicles:light_barrier2", {
description = S("Light Barrier 2"),
tiles = {"vehicles_lightblock2.png",},
tiles = {
"vehicles_lightblock2.png^[transformR90",
"vehicles_lightblock2.png^[transformR90",
"vehicles_lightblock2.png",
},
use_texture_alpha = true,
drawtype = "allfaces",
drawtype = "nodebox",
paramtype = "light",
paramtype2 = "facedir",
node_box = {
type = "fixed",
fixed = {
{-0.0625, -0.5, -0.5, 0.0625, 0.5, 0.5},
}
},
sunlight_propagates = true,
walkable = false,
light_source = 9,
is_ground_content = true,
groups = {cracky=3,dig_immediate=3,not_in_creative_inventory=1},
on_construct = function(pos, node)
minetest.get_node_timer(pos):start(4)
return
end,
on_timer = function(pos, elapsed)
minetest.remove_node(pos)

Binary file not shown.

Before

Width:  |  Height:  |  Size: 155 B

After

Width:  |  Height:  |  Size: 356 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 150 B

After

Width:  |  Height:  |  Size: 245 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB