Convert computer tower in mesh
@@ -151,7 +151,7 @@ minetest.register_node("computer:monitor", {
 | 
			
		||||
	description = "Monitor and keyboard",
 | 
			
		||||
	drawtype = "mesh",
 | 
			
		||||
	mesh = "computer_monitor.obj",
 | 
			
		||||
	tiles = {"computer_black.png", "monitor_plastic.png", "computer_black.png", "monitor_plastic.png"},
 | 
			
		||||
	tiles = {"monitor_plastic.png", "monitor_plastic.png", "computer_black.png", "computer_black.png"},
 | 
			
		||||
	paramtype = "light",
 | 
			
		||||
	paramtype2 = "facedir",
 | 
			
		||||
	walkable = false,
 | 
			
		||||
@@ -167,7 +167,7 @@ minetest.register_node("computer:monitor_on", {
 | 
			
		||||
	description = "Monitor and keyboard",
 | 
			
		||||
	drawtype = "mesh",
 | 
			
		||||
	mesh = "computer_monitor.obj",
 | 
			
		||||
	tiles = {"computer_black.png", "monitor_plastic.png", "monitor_display.png^[transformR90", "monitor_plastic.png"},
 | 
			
		||||
	tiles = {"monitor_plastic.png", "monitor_plastic.png", "computer_black.png", "monitor_display.png^[transformR90"},
 | 
			
		||||
	paramtype = "light",
 | 
			
		||||
	paramtype2 = "facedir",
 | 
			
		||||
	light_source = 9,
 | 
			
		||||
@@ -208,68 +208,27 @@ minetest.register_node("computer:router", {
 | 
			
		||||
	}
 | 
			
		||||
})
 | 
			
		||||
 | 
			
		||||
--Modern PC Tower
 | 
			
		||||
minetest.register_node("computer:tower_on", {
 | 
			
		||||
	description = "Computer Tower",
 | 
			
		||||
	tiles = {"computer_tower_t.png","computer_tower_bt.png","computer_tower_l.png",
 | 
			
		||||
			"computer_tower_r.png","computer_tower_b.png","computer_tower_f_on.png"},
 | 
			
		||||
	paramtype = "light",
 | 
			
		||||
	paramtype2 = "facedir",
 | 
			
		||||
	walkable = true,
 | 
			
		||||
	groups = {snappy=3, not_in_creative_inventory=1},
 | 
			
		||||
	sound = default.node_sound_wood_defaults(),
 | 
			
		||||
	drawtype = "nodebox",
 | 
			
		||||
	node_box = {
 | 
			
		||||
		type = "fixed",
 | 
			
		||||
		fixed = {
 | 
			
		||||
			{-0.1875, -0.5, -0.3125, 0.1875, 0.3125, 0.4375},
 | 
			
		||||
			{-0.1875, -0.5, -0.353774, 0.1875, 0, -0.0625},
 | 
			
		||||
			{-0.1875, 0.247641, -0.353774, 0.1875, 0.3125, 0.1875}
 | 
			
		||||
		},
 | 
			
		||||
	},
 | 
			
		||||
	selection_box = {
 | 
			
		||||
		type = "fixed",
 | 
			
		||||
		fixed = {
 | 
			
		||||
			{-0.1875, -0.5, -0.3125, 0.1875, 0.3125, 0.4375},
 | 
			
		||||
		},
 | 
			
		||||
	},
 | 
			
		||||
	drop = 'computer:tower',
 | 
			
		||||
	on_rightclick = function(pos, node, clicker, itemstack)
 | 
			
		||||
		node.name = "computer:tower"
 | 
			
		||||
		minetest.set_node(pos, node)
 | 
			
		||||
	end
 | 
			
		||||
})
 | 
			
		||||
local pct_cbox = {
 | 
			
		||||
	type = "fixed",
 | 
			
		||||
	fixed = { -0.1875, -0.5, -0.36, 0.1875, 0.34, 0.46 }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
--Modern PC Tower
 | 
			
		||||
minetest.register_node("computer:tower", {
 | 
			
		||||
	description = "Computer Tower",
 | 
			
		||||
	tiles = {"computer_tower_t.png","computer_tower_bt.png","computer_tower_l.png","computer_tower_r.png",
 | 
			
		||||
			"computer_tower_b.png","computer_tower_f_off.png"},
 | 
			
		||||
	drawtype = "mesh",
 | 
			
		||||
	mesh = "computer_tower.obj",
 | 
			
		||||
	tiles = {"computer_tower.png"},
 | 
			
		||||
	paramtype = "light",
 | 
			
		||||
	paramtype2 = "facedir",
 | 
			
		||||
	walkable = true,
 | 
			
		||||
	groups = {snappy=3},
 | 
			
		||||
	sound = default.node_sound_wood_defaults(),
 | 
			
		||||
	drawtype = "nodebox",
 | 
			
		||||
	node_box = {
 | 
			
		||||
		type = "fixed",
 | 
			
		||||
		fixed = {
 | 
			
		||||
			{-0.1875, -0.5, -0.3125, 0.1875, 0.3125, 0.4375},
 | 
			
		||||
			{-0.1875, -0.5, -0.353774, 0.1875, 0, -0.0625},
 | 
			
		||||
			{-0.1875, 0.247641, -0.353774, 0.1875, 0.3125, 0.1875},
 | 
			
		||||
		},
 | 
			
		||||
	},
 | 
			
		||||
	selection_box = {
 | 
			
		||||
		type = "fixed",
 | 
			
		||||
		fixed = {
 | 
			
		||||
			{-0.1875, -0.5, -0.3125, 0.1875, 0.3125, 0.4375},
 | 
			
		||||
		},
 | 
			
		||||
	},
 | 
			
		||||
	on_rightclick = function(pos, node, clicker, itemstack)
 | 
			
		||||
		node.name = "computer:tower_on"
 | 
			
		||||
		minetest.set_node(pos, node)
 | 
			
		||||
	end
 | 
			
		||||
	selection_box = pct_cbox,
 | 
			
		||||
	collision_box = pct_cbox
 | 
			
		||||
})
 | 
			
		||||
 | 
			
		||||
minetest.register_alias("computer:tower_on", "computer:tower")
 | 
			
		||||
 | 
			
		||||
-- Printer/scaner combo
 | 
			
		||||
minetest.register_node("computer:printer", {
 | 
			
		||||
	description = "Printer Scaner Combo",
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										33
									
								
								computer/models/computer_tower.obj
									
									
									
									
									
										Normal file
									
								
							
							
						
						@@ -0,0 +1,33 @@
 | 
			
		||||
# Blender v2.72 (sub 0) OBJ File: ''
 | 
			
		||||
# www.blender.org
 | 
			
		||||
mtllib computer_tower.mtl
 | 
			
		||||
o Cube.001
 | 
			
		||||
v -0.182508 -0.499998 0.450000
 | 
			
		||||
v -0.182508 -0.499998 -0.349946
 | 
			
		||||
v 0.182508 -0.499998 -0.349946
 | 
			
		||||
v 0.182508 -0.499998 0.450000
 | 
			
		||||
v -0.182508 0.335734 0.450000
 | 
			
		||||
v 0.182508 0.335734 0.450000
 | 
			
		||||
v 0.182508 0.335734 -0.349946
 | 
			
		||||
v -0.182508 0.335734 -0.349947
 | 
			
		||||
vt 0.999994 0.750017
 | 
			
		||||
vt 0.500006 0.749983
 | 
			
		||||
vt 0.500002 0.499996
 | 
			
		||||
vt 0.999997 0.500009
 | 
			
		||||
vt 0.499989 0.999941
 | 
			
		||||
vt 0.999986 0.999931
 | 
			
		||||
vt 0.500005 0.000003
 | 
			
		||||
vt 0.000007 0.500002
 | 
			
		||||
vt -0.000003 0.000003
 | 
			
		||||
vt 0.250005 0.999991
 | 
			
		||||
vt 0.250005 0.499995
 | 
			
		||||
vt 0.999993 0.000002
 | 
			
		||||
vt 0.000017 0.999997
 | 
			
		||||
usemtl Material.001
 | 
			
		||||
s off
 | 
			
		||||
f 1/1 2/2 3/3 4/4
 | 
			
		||||
f 5/5 6/2 7/1 8/6
 | 
			
		||||
f 1/7 5/3 8/8 2/9
 | 
			
		||||
f 2/3 8/5 7/10 3/11
 | 
			
		||||
f 3/12 7/4 6/3 4/7
 | 
			
		||||
f 5/13 1/8 4/11 6/10
 | 
			
		||||
							
								
								
									
										
											BIN
										
									
								
								computer/textures/computer_tower.png
									
									
									
									
									
										Normal file
									
								
							
							
						
						| 
		 After Width: | Height: | Size: 7.5 KiB  | 
| 
		 Before Width: | Height: | Size: 355 B  | 
| 
		 Before Width: | Height: | Size: 83 B  | 
| 
		 Before Width: | Height: | Size: 282 B  | 
| 
		 Before Width: | Height: | Size: 286 B  | 
| 
		 Before Width: | Height: | Size: 148 B  | 
| 
		 Before Width: | Height: | Size: 201 B  | 
| 
		 Before Width: | Height: | Size: 83 B  |