Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Tool specific pointing and blocking pointable type (#13992)
- Loading branch information
Showing
39 changed files
with
676 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
dofile(minetest.get_modpath("testentities").."/visuals.lua") | ||
dofile(minetest.get_modpath("testentities").."/selectionbox.lua") | ||
dofile(minetest.get_modpath("testentities").."/armor.lua") | ||
dofile(minetest.get_modpath("testentities").."/pointable.lua") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
-- Pointability test Entities | ||
|
||
-- Register wrapper for compactness | ||
local function register_pointable_testentity(name, pointable) | ||
local texture = "testnodes_"..name..".png" | ||
minetest.register_entity("testentities:"..name, { | ||
initial_properties = { | ||
visual = "cube", | ||
visual_size = {x = 0.6, y = 0.6, z = 0.6}, | ||
textures = { | ||
texture, texture, texture, texture, texture, texture | ||
}, | ||
pointable = pointable, | ||
}, | ||
on_activate = function(self) | ||
self.object:set_armor_groups({[name.."_test"] = 1}) | ||
end | ||
}) | ||
end | ||
|
||
register_pointable_testentity("pointable", true) | ||
register_pointable_testentity("not_pointable", false) | ||
register_pointable_testentity("blocking_pointable", "blocking") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file added
BIN
+150 Bytes
games/devtest/mods/testnodes/textures/testnodes_blocking_pointable.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file added
BIN
+136 Bytes
games/devtest/mods/testtools/textures/testtools_blocked_pointing_staff.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+136 Bytes
games/devtest/mods/testtools/textures/testtools_ultimate_pointing_staff.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.