Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
illuna-minetest
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Illuna-Minetest
illuna-minetest
Commits
2fb0e547
Commit
2fb0e547
authored
11 years ago
by
Diego Martínez
Committed by
PilzAdam
11 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Use the nodebox as selection box if it's not set manually
parent
1a5dcfd0
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
builtin/misc_register.lua
+4
-0
4 additions, 0 deletions
builtin/misc_register.lua
doc/lua_api.txt
+1
-0
1 addition, 0 deletions
doc/lua_api.txt
with
5 additions
and
0 deletions
builtin/misc_register.lua
+
4
−
0
View file @
2fb0e547
...
...
@@ -103,6 +103,10 @@ function minetest.register_item(name, itemdef)
-- Apply defaults and add to registered_* table
if itemdef.type == "
node
" then
-- Use the nodebox as selection box if it's not set manually
if itemdef.drawtype == "
nodebox
" and not itemdef.selection_box then
itemdef.selection_box = itemdef.node_box
end
setmetatable(itemdef, {__index = minetest.nodedef_default})
minetest.registered_nodes[itemdef.name] = itemdef
elseif itemdef.type == "
craft
" then
...
...
This diff is collapsed.
Click to expand it.
doc/lua_api.txt
+
1
−
0
View file @
2fb0e547
...
...
@@ -1589,6 +1589,7 @@ Node definition (register_node)
damage_per_second = 0, -- If player is inside node, this damage is caused
node_box = {type="regular"}, -- See "Node boxes"
selection_box = {type="regular"}, -- See "Node boxes"
^ If drawtype "nodebox" is used and selection_box is nil, then node_box is used
legacy_facedir_simple = false, -- Support maps made in and before January 2012
legacy_wallmounted = false, -- Support maps made in and before January 2012
sounds = {
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment