Add files via upload

UPDATED ROADS AND INIT
master
Steamed-Punk 2020-10-26 02:02:21 +01:00 committed by GitHub
parent 6843e95a5f
commit 6ec8751320
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 222 additions and 35 deletions

View File

@ -10,17 +10,15 @@
-- NODES
-- ROADS
-- STRAIGHT
-- ROADS NO TRACKS
minetest.register_node("mt_buildings:mtv_road", {
description = "Road Straight",
-- SINGLE
minetest.register_node("mt_buildings:mtv_road_base_single", {
description = "Road Base Single",
drawtype = "mesh",
mesh = "mtv_road_straight.obj",
tiles = {"road_straight.png"},
mesh = "mtv_road_block_base_single.obj",
tiles = {"road_base.png"},
use_texture_alpha = true,
inventory_image = "road_straight.png",
wield_image = "road_straight.png",
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
@ -28,11 +26,158 @@ minetest.register_node("mt_buildings:mtv_road", {
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.3, 0.5},
fixed = {-0.5, -0.5, -0.5, 0.5, 0.5, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.3, 0.5},
fixed = {-0.5, -0.5, -0.5, 0.5, 0.5, 0.5},
},
on_place = minetest.rotate_node,
})
-- FULL
minetest.register_node("mt_buildings:mtv_road_base_full", {
description = "Road Base Full",
drawtype = "mesh",
mesh = "mtv_road_block_base_full.obj",
tiles = {"road_base.png"},
use_texture_alpha = true,
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
light_source = 4,
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 1.5, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 1.5, 0.5},
},
on_place = minetest.rotate_node,
})
-- HALF
minetest.register_node("mt_buildings:mtv_road_base_half", {
description = "Road Base Half",
drawtype = "mesh",
mesh = "mtv_road_block_base_half.obj",
tiles = {"road_base.png"},
use_texture_alpha = true,
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
light_source = 4,
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-0.5, -0.5, -1.5, 0.5, 0.5, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-1, -0.5, -1.5, 0.5, 0.5, 0.5},
},
on_place = minetest.rotate_node,
})
-- BASE
minetest.register_node("mt_buildings:mtv_road_base", {
description = "Road Base",
drawtype = "mesh",
mesh = "mtv_road_block_base.obj",
tiles = {"road_base.png"},
use_texture_alpha = true,
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
light_source = 4,
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.5, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.5, 0.5},
},
on_place = minetest.rotate_node,
})
-- RAMP BASE
minetest.register_node("mt_buildings:mtv_road_ramp_base", {
description = "Road Base Ramp",
drawtype = "mesh",
mesh = "mtv_road_block_ramp.obj",
tiles = {"road_base.png"},
use_texture_alpha = true,
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
light_source = 4,
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-1.5, -0.5, -0.5, 0.5, 0, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-1.5, -0.5, -0.5, 0.5, 0, 0.5},
},
on_place = minetest.rotate_node,
})
-- RAMP BASE HALF
minetest.register_node("mt_buildings:mtv_road_ramp_base_half", {
description = "Road Base Ramp Half",
drawtype = "mesh",
mesh = "mtv_road_block_ramp_half.obj",
tiles = {"road_base.png"},
use_texture_alpha = true,
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
light_source = 4,
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-0.5, -0.5, -0.5, 0.5, 0, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-0.5, -0.5, -0.5, 0.5, 0, 0.5},
},
on_place = minetest.rotate_node,
})
-- ROADS TRACKS
-- STRAIGHT
minetest.register_node("mt_buildings:mtv_road", {
description = "Road Straight",
drawtype = "mesh",
mesh = "mtv_road_block_base.obj",
tiles = {"road_straight.png"},
use_texture_alpha = true,
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
light_source = 4,
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.5, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.5, 0.5},
},
on_place = minetest.rotate_node,
@ -43,11 +188,9 @@ minetest.register_node("mt_buildings:mtv_road", {
minetest.register_node("mt_buildings:mtv_road_corner", {
description = "Road Corner",
drawtype = "mesh",
mesh = "mtv_road_corner.obj",
mesh = "mtv_road_block_base.obj",
tiles = {"road_corner.png"},
use_texture_alpha = true,
inventory_image = "road_corner.png",
wield_image = "road_corner.png",
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
@ -55,11 +198,11 @@ minetest.register_node("mt_buildings:mtv_road_corner", {
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.3, 0.5},
fixed = {-1.5, -0.5, -1.5, 0.5, 0.5, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.3, 0.5},
fixed = {-1.5, -0.5, -1.5, 0.5, 0.5, 0.5},
},
on_place = minetest.rotate_node,
@ -70,11 +213,9 @@ minetest.register_node("mt_buildings:mtv_road_corner", {
minetest.register_node("mt_buildings:mtv_road_crossroad", {
description = "Road Crossroad",
drawtype = "mesh",
mesh = "mtv_road_straight.obj",
mesh = "mtv_road_block_base.obj",
tiles = {"road_crossroad.png"},
use_texture_alpha = true,
inventory_image = "road_crossroad.png",
wield_image = "road_crossroad.png",
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
@ -82,27 +223,52 @@ minetest.register_node("mt_buildings:mtv_road_crossroad", {
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.3, 0.5},
fixed = {-1.5, -0.5, -1.5, 0.5, 0.5, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.3, 0.5},
fixed = {-1.5, -0.5, -1.5, 0.5, 0.5, 0.5},
},
on_place = minetest.rotate_node,
})
-- RAMP STRAIGHT
minetest.register_node("mt_buildings:mtv_road_ramp_straight", {
description = "Road Ramp",
drawtype = "mesh",
mesh = "mtv_road_block_ramp.obj",
tiles = {"road_straight.png"},
use_texture_alpha = true,
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
light_source = 4,
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-1.5, -0.5, -0.5, 0.5, 0, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-1.5, -0.5, -0.5, 0.5, 0, 0.5},
},
on_place = minetest.rotate_node,
})
-- ROAD_EDGES
-- FULL
-- STRAIGHT
minetest.register_node("mt_buildings:mtv_road_edge", {
description = "Road Edge",
description = "Road Edge Straight",
drawtype = "mesh",
mesh = "mtv_road_edge.obj",
mesh = "mtv_road_edge_straight.obj",
tiles = {"road_edge_straight.png"},
use_texture_alpha = true,
inventory_image = "road_edge_straight.png",
wield_image = "road_edge_straight.png",
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
@ -110,11 +276,11 @@ minetest.register_node("mt_buildings:mtv_road_edge", {
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.4, 0.5},
fixed = {-1.5, -0.5, -1, 0.5, 0, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.4, 0.5},
fixed = {-1.5, -0.5, -1, 0.5, 0, 0.5},
},
on_place = minetest.rotate_node,
@ -127,8 +293,6 @@ minetest.register_node("mt_buildings:mtv_road_edge_corner_out", {
mesh = "mtv_road_edge_corner_out.obj",
tiles = {"road_edge_corner_out.png"},
use_texture_alpha = true,
inventory_image = "road_edge_corner_out.png",
wield_image = "road_edge_corner_out.png",
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
@ -136,11 +300,11 @@ minetest.register_node("mt_buildings:mtv_road_edge_corner_out", {
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.4, 0.5},
fixed = {-1.5, -0.5, -1.5, 0.5, 0, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.4, 0.5},
fixed = {-1.5, -0.5, -1.5, 0.5, 0, 0.5},
},
on_place = minetest.rotate_node,
@ -153,8 +317,6 @@ minetest.register_node("mt_buildings:mtv_road_edge_corner_in", {
mesh = "mtv_road_edge_corner_in.obj",
tiles = {"road_edge_corner_in.png"},
use_texture_alpha = true,
inventory_image = "road_edge_corner_in.png",
wield_image = "road_edge_corner_in.png",
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
@ -162,14 +324,39 @@ minetest.register_node("mt_buildings:mtv_road_edge_corner_in", {
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.4, 0.5},
fixed = {-1, -0.5, -1, 0.5, 0, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-1.5, -0.5, -1.5, 0.5, 0.4, 0.5},
fixed = {-1, -0.5, -1, 0.5, 0, 0.5},
},
on_place = minetest.rotate_node,
})
-- STREETLIGHT_CRAFT
-- HALF
minetest.register_node("mt_buildings:mtv_road_edge_half", {
description = "Road Edge Half",
drawtype = "mesh",
mesh = "mtv_road_edge_straight_half.obj",
tiles = {"road_edge_straight.png"},
use_texture_alpha = true,
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
light_source = 4,
groups = {choppy=2, oddly_breakable_by_hand=2, flammable=3},
selection_box = {
type = "fixed",
fixed = {-0.5, -0.5, -1, 0.5, 0, 0.5},
},
collision_box = {
type = "fixed",
fixed = {-0.5, -0.5, -1, 0.5, 0, 0.5},
},
on_place = minetest.rotate_node,
})
-- ROAD_CRAFT