mirror of
https://git.minetest.land/VoxeLibre/VoxeLibre.git
synced 2024-11-28 05:21:05 +01:00
Re-enable rule for powering rail from underneath, have stairs block minecart movement, fix crash when lightning strikes a minecart
This commit is contained in:
parent
4589206985
commit
ad11fc22ec
2 changed files with 3 additions and 3 deletions
|
@ -695,7 +695,7 @@ local function register_entity(entity_id, def)
|
|||
|
||||
-- Drop items
|
||||
local drop = def.drop
|
||||
if not minetest.is_creative_enabled(killer:get_player_name()) then
|
||||
if not killer or not minetest.is_creative_enabled(killer:get_player_name()) then
|
||||
for d=1, #drop do
|
||||
minetest.add_item(self.object:get_pos(), drop[d])
|
||||
end
|
||||
|
|
|
@ -165,7 +165,7 @@ local function rail_dir_straight(pos, dir, node)
|
|||
local next_pos = vector.add(pos, raw_dir)
|
||||
local next_node = minetest.get_node(next_pos)
|
||||
local node_def = minetest.registered_nodes[next_node.name]
|
||||
if node_def and node_def.groups and node_def.groups.solid then
|
||||
if node_def and node_def.groups and ( node_def.groups.solid or node_def.groups.stair ) then
|
||||
-- Reverse the direction without giving -0 members
|
||||
return vector.direction(next_pos, pos)
|
||||
else
|
||||
|
@ -359,7 +359,7 @@ mod.register_rail_sloped = register_rail_sloped
|
|||
local rail_rules_long =
|
||||
{{x=-1, y= 0, z= 0, spread=true},
|
||||
{x= 1, y= 0, z= 0, spread=true},
|
||||
-- {x= 0, y=-1, z= 0, spread=true},
|
||||
{x= 0, y=-1, z= 0, spread=true},
|
||||
{x= 0, y= 1, z= 0, spread=true},
|
||||
{x= 0, y= 0, z=-1, spread=true},
|
||||
{x= 0, y= 0, z= 1, spread=true},
|
||||
|
|
Loading…
Reference in a new issue