forked from mtcontrib/maidroid
[UPDATE] Update something
This commit is contained in:
parent
139f8f00d1
commit
72f08d1611
@ -41,21 +41,48 @@ end) ();
|
|||||||
|
|
||||||
-- register a definition of a core entity.
|
-- register a definition of a core entity.
|
||||||
(function()
|
(function()
|
||||||
|
local node_box = {
|
||||||
|
type = "fixed",
|
||||||
|
fixed = {
|
||||||
|
{ -0.5, -0.5, -0.125, 0.5, -0.4375, 0.125},
|
||||||
|
{ -0.125, -0.5, -0.5, 0.125, -0.4375, 0.5},
|
||||||
|
{ -0.25, -0.5, -0.4375, 0.25, -0.4375, 0.4375},
|
||||||
|
{ -0.375, -0.5, -0.375, 0.375, -0.4375, 0.375},
|
||||||
|
{-0.4375, -0.5, -0.25, 0.4375, -0.4375, 0.25},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
local tiles = {
|
||||||
|
"maidroid_tool_core_top.png",
|
||||||
|
"maidroid_tool_core_top.png",
|
||||||
|
"maidroid_tool_core_right.png",
|
||||||
|
"maidroid_tool_core_right.png",
|
||||||
|
"maidroid_tool_core_right.png",
|
||||||
|
"maidroid_tool_core_right.png",
|
||||||
|
}
|
||||||
|
|
||||||
minetest.register_node("maidroid_tool:core_node", {
|
minetest.register_node("maidroid_tool:core_node", {
|
||||||
tiles = {"maidroid_core_empty.png"},
|
drawtype = "nodebox",
|
||||||
|
tiles = tiles,
|
||||||
|
node_box = node_box,
|
||||||
|
paramtype = "light",
|
||||||
|
paramtype2 = "facedir",
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
minetest.register_entity("maidroid_tool:core_entity", {
|
minetest.register_entity("maidroid_tool:core_entity", {
|
||||||
physical = false,
|
physical = false,
|
||||||
visual = "wielditem",
|
visual = "wielditem",
|
||||||
visual_size = {x = 0.5, y = 0.5},
|
visual_size = {x = 0.5, y = 0.5},
|
||||||
nodename = "maidroid_tool:core_node",
|
collisionbox = {0, 0, 0, 0, 0, 0},
|
||||||
|
|
||||||
on_activate = function(self, staticdata)
|
on_activate = function(self, staticdata)
|
||||||
self.object:set_properties{textures = {"maidroid_tool:core_node"}}
|
self.object:set_properties{textures = {"maidroid_tool:core_node"}}
|
||||||
end,
|
end,
|
||||||
|
|
||||||
|
on_step = function(self, dtime)
|
||||||
|
local yaw = self.object:getyaw()
|
||||||
|
self.object:setyaw(yaw + 0.1)
|
||||||
|
end,
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_on_punchnode(function(pos, node, puncher, pointed_thing)
|
minetest.register_on_punchnode(function(pos, node, puncher, pointed_thing)
|
||||||
|
BIN
maidroid_tool/textures/maidroid_tool_core_right.png
Normal file
BIN
maidroid_tool/textures/maidroid_tool_core_right.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 676 B |
BIN
maidroid_tool/textures/maidroid_tool_core_right.xcf
Normal file
BIN
maidroid_tool/textures/maidroid_tool_core_right.xcf
Normal file
Binary file not shown.
BIN
maidroid_tool/textures/maidroid_tool_core_top.png
Normal file
BIN
maidroid_tool/textures/maidroid_tool_core_top.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 996 B |
BIN
maidroid_tool/textures/maidroid_tool_core_top.xcf
Normal file
BIN
maidroid_tool/textures/maidroid_tool_core_top.xcf
Normal file
Binary file not shown.
Loading…
Reference in New Issue
Block a user