homedecor_modpack/door_models.lua
Vanessa Ezekowitz 94af6653fd completely rewrote all doors code to condense them
into two files - one with the nodebox models, and one with the
actual node definitions.

In the process, cleaned up the code that handles node_ownership
and protection mods.

Also made the mod automatically enable either left-click or right-click to
open/close a door, depending on whether the game supports it (actually it
checks for the existance of an unrelated function that happened to be added at
the same time as the new right-click function).

Renamed some textures, duplicated all of the _lr.png textures to make it
easier to register the textures in a loop and to allow for more flexible
texturing.
2013-01-23 05:45:42 -05:00

318 lines
11 KiB
Lua

homedecor_door_models = {
{
"closet_mahogany",
"Mahogany Closet Door",
{{ -8/16, 5/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, 8/32, 13/32, 8/16, 9/32, 15/32 },
{ -8/16, 6/32, 13/32, 8/16, 7/32, 15/32 },
{ -8/16, 4/32, 13/32, 8/16, 5/32, 15/32 },
{ -8/16, 2/32, 13/32, 8/16, 3/32, 15/32 },
{ -8/16, 0/32, 13/32, 8/16, 1/32, 15/32 },
{ -8/16, -2/32, 13/32, 8/16, -1/32, 15/32 },
{ -8/16, -4/32, 13/32, 8/16, -3/32, 15/32 },
{ -8/16, -6/32, 13/32, 8/16, -5/32, 15/32 },
{ -8/16, -8/32, 13/32, 8/16, -7/32, 15/32 },
{ -8/16, -10/32, 13/32, 8/16, -9/32, 15/32 },
{ -8/16, -12/32, 13/32, 8/16, -11/32, 15/32 },
{ -8/16, -16/32, 6/16, 8/16, -13/32, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 }},
{{ -8/16, 6/16, 6/16, 8/16, 8/16, 8/16},
{ -8/16, 10/32, 13/32, 8/16, 11/32, 15/32 },
{ -8/16, 8/32, 13/32, 8/16, 9/32, 15/32 },
{ -8/16, 6/32, 13/32, 8/16, 7/32, 15/32 },
{ -8/16, 4/32, 13/32, 8/16, 5/32, 15/32 },
{ -8/16, 2/32, 13/32, 8/16, 3/32, 15/32 },
{ -8/16, 0, 13/32, 8/16, 1/32, 15/32 },
{ -8/16, -2/32, 13/32, 8/16, -1/32, 15/32 },
{ -8/16, -4/32, 13/32, 8/16, -3/32, 15/32 },
{ -8/16, -6/32, 13/32, 8/16, -5/32, 15/32 },
{ -8/16, -8/32, 13/32, 8/16, -7/32, 15/32 },
{ -8/16, -10/32, 13/32, 8/16, -9/32, 15/32 },
{ -8/16, -16/32, 6/16, 8/16, -11/32, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 }},
{{ -8/16, 5/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, 8/32, 13/32, 8/16, 9/32, 15/32 },
{ -8/16, 6/32, 13/32, 8/16, 7/32, 15/32 },
{ -8/16, 4/32, 13/32, 8/16, 5/32, 15/32 },
{ -8/16, 2/32, 13/32, 8/16, 3/32, 15/32 },
{ -8/16, 0/32, 13/32, 8/16, 1/32, 15/32 },
{ -8/16, -2/32, 13/32, 8/16, -1/32, 15/32 },
{ -8/16, -4/32, 13/32, 8/16, -3/32, 15/32 },
{ -8/16, -6/32, 13/32, 8/16, -5/32, 15/32 },
{ -8/16, -8/32, 13/32, 8/16, -7/32, 15/32 },
{ -8/16, -10/32, 13/32, 8/16, -9/32, 15/32 },
{ -8/16, -12/32, 13/32, 8/16, -11/32, 15/32 },
{ -8/16, -16/32, 6/16, 8/16, -13/32, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 }},
{{ -8/16, 6/16, 6/16, 8/16, 8/16, 8/16},
{ -8/16, 10/32, 13/32, 8/16, 11/32, 15/32 },
{ -8/16, 8/32, 13/32, 8/16, 9/32, 15/32 },
{ -8/16, 6/32, 13/32, 8/16, 7/32, 15/32 },
{ -8/16, 4/32, 13/32, 8/16, 5/32, 15/32 },
{ -8/16, 2/32, 13/32, 8/16, 3/32, 15/32 },
{ -8/16, 0, 13/32, 8/16, 1/32, 15/32 },
{ -8/16, -2/32, 13/32, 8/16, -1/32, 15/32 },
{ -8/16, -4/32, 13/32, 8/16, -3/32, 15/32 },
{ -8/16, -6/32, 13/32, 8/16, -5/32, 15/32 },
{ -8/16, -8/32, 13/32, 8/16, -7/32, 15/32 },
{ -8/16, -10/32, 13/32, 8/16, -9/32, 15/32 },
{ -8/16, -16/32, 6/16, 8/16, -11/32, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 }}
},
----------
{
"closet_oak",
"Oak Closet Door",
{{ -8/16, 5/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, 8/32, 13/32, 8/16, 9/32, 15/32 },
{ -8/16, 6/32, 13/32, 8/16, 7/32, 15/32 },
{ -8/16, 4/32, 13/32, 8/16, 5/32, 15/32 },
{ -8/16, 2/32, 13/32, 8/16, 3/32, 15/32 },
{ -8/16, 0/32, 13/32, 8/16, 1/32, 15/32 },
{ -8/16, -2/32, 13/32, 8/16, -1/32, 15/32 },
{ -8/16, -4/32, 13/32, 8/16, -3/32, 15/32 },
{ -8/16, -6/32, 13/32, 8/16, -5/32, 15/32 },
{ -8/16, -8/32, 13/32, 8/16, -7/32, 15/32 },
{ -8/16, -10/32, 13/32, 8/16, -9/32, 15/32 },
{ -8/16, -12/32, 13/32, 8/16, -11/32, 15/32 },
{ -8/16, -16/32, 6/16, 8/16, -13/32, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 }},
{{ -8/16, 6/16, 6/16, 8/16, 8/16, 8/16},
{ -8/16, 10/32, 13/32, 8/16, 11/32, 15/32 },
{ -8/16, 8/32, 13/32, 8/16, 9/32, 15/32 },
{ -8/16, 6/32, 13/32, 8/16, 7/32, 15/32 },
{ -8/16, 4/32, 13/32, 8/16, 5/32, 15/32 },
{ -8/16, 2/32, 13/32, 8/16, 3/32, 15/32 },
{ -8/16, 0, 13/32, 8/16, 1/32, 15/32 },
{ -8/16, -2/32, 13/32, 8/16, -1/32, 15/32 },
{ -8/16, -4/32, 13/32, 8/16, -3/32, 15/32 },
{ -8/16, -6/32, 13/32, 8/16, -5/32, 15/32 },
{ -8/16, -8/32, 13/32, 8/16, -7/32, 15/32 },
{ -8/16, -10/32, 13/32, 8/16, -9/32, 15/32 },
{ -8/16, -16/32, 6/16, 8/16, -11/32, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 }},
{{ -8/16, 5/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, 8/32, 13/32, 8/16, 9/32, 15/32 },
{ -8/16, 6/32, 13/32, 8/16, 7/32, 15/32 },
{ -8/16, 4/32, 13/32, 8/16, 5/32, 15/32 },
{ -8/16, 2/32, 13/32, 8/16, 3/32, 15/32 },
{ -8/16, 0/32, 13/32, 8/16, 1/32, 15/32 },
{ -8/16, -2/32, 13/32, 8/16, -1/32, 15/32 },
{ -8/16, -4/32, 13/32, 8/16, -3/32, 15/32 },
{ -8/16, -6/32, 13/32, 8/16, -5/32, 15/32 },
{ -8/16, -8/32, 13/32, 8/16, -7/32, 15/32 },
{ -8/16, -10/32, 13/32, 8/16, -9/32, 15/32 },
{ -8/16, -12/32, 13/32, 8/16, -11/32, 15/32 },
{ -8/16, -16/32, 6/16, 8/16, -13/32, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 }},
{{ -8/16, 6/16, 6/16, 8/16, 8/16, 8/16},
{ -8/16, 10/32, 13/32, 8/16, 11/32, 15/32 },
{ -8/16, 8/32, 13/32, 8/16, 9/32, 15/32 },
{ -8/16, 6/32, 13/32, 8/16, 7/32, 15/32 },
{ -8/16, 4/32, 13/32, 8/16, 5/32, 15/32 },
{ -8/16, 2/32, 13/32, 8/16, 3/32, 15/32 },
{ -8/16, 0, 13/32, 8/16, 1/32, 15/32 },
{ -8/16, -2/32, 13/32, 8/16, -1/32, 15/32 },
{ -8/16, -4/32, 13/32, 8/16, -3/32, 15/32 },
{ -8/16, -6/32, 13/32, 8/16, -5/32, 15/32 },
{ -8/16, -8/32, 13/32, 8/16, -7/32, 15/32 },
{ -8/16, -10/32, 13/32, 8/16, -9/32, 15/32 },
{ -8/16, -16/32, 6/16, 8/16, -11/32, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 }},
},
----------
{
"exterior_fancy",
"Fancy Wood/Glass Door",
{{ -8/16, 6/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }},
{{ -8/16, -8/16, 6/16, 8/16, 6/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }},
{{ -8/16, 6/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }},
{{ -8/16, -8/16, 6/16, 8/16, 6/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }}
},
----------
{
"glass",
"Glass Office Door",
{{ -8/16, -8/16, 6/16, 8/16, 8/16, 8/16 }},
{{ -8/16, -8/16, 6/16, 8/16, 8/16, 8/16 }},
{{ -8/16, -8/16, 6/16, 8/16, 8/16, 8/16 }},
{{ -8/16, -8/16, 6/16, 8/16, 8/16, 8/16 }}
},
----------
{
"wood_glass",
"Glass and Wood, Oak-colored",
{{ -8/16, 6/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -3/32, 6/16, 8/16, 1/32, 8/16 },
{ -8/16, -8/16, 6/16, 8/16, -7/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ -1/16, -8/16, 6/16, 1/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }},
{{ -8/16, 7/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -1/32, 6/16, 8/16, 3/32, 8/16 },
{ -8/16, -8/16, 6/16, 8/16, -6/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ -1/16, -8/16, 6/16, 1/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }},
{{ -8/16, 6/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -3/32, 6/16, 8/16, 1/32, 8/16 },
{ -8/16, -8/16, 6/16, 8/16, -7/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ -1/16, -8/16, 6/16, 1/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }},
{{ -8/16, 7/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -1/32, 6/16, 8/16, 3/32, 8/16 },
{ -8/16, -8/16, 6/16, 8/16, -6/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ -1/16, -8/16, 6/16, 1/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }}
},
----------
{
"wood_glass_mahogany",
"Glass and Wood, Mahogany-colored",
{{ -8/16, 6/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -3/32, 6/16, 8/16, 1/32, 8/16 },
{ -8/16, -8/16, 6/16, 8/16, -7/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ -1/16, -8/16, 6/16, 1/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }},
{{ -8/16, 7/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -1/32, 6/16, 8/16, 3/32, 8/16 },
{ -8/16, -8/16, 6/16, 8/16, -6/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ -1/16, -8/16, 6/16, 1/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }},
{{ -8/16, 6/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -3/32, 6/16, 8/16, 1/32, 8/16 },
{ -8/16, -8/16, 6/16, 8/16, -7/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ -1/16, -8/16, 6/16, 1/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }},
{{ -8/16, 7/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -1/32, 6/16, 8/16, 3/32, 8/16 },
{ -8/16, -8/16, 6/16, 8/16, -6/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ -1/16, -8/16, 6/16, 1/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }}
},
----------
{
"wood_glass_white",
"Glass and Wood, White",
{{ -8/16, 6/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -3/32, 6/16, 8/16, 1/32, 8/16 },
{ -8/16, -8/16, 6/16, 8/16, -7/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ -1/16, -8/16, 6/16, 1/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }},
{{ -8/16, 7/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -1/32, 6/16, 8/16, 3/32, 8/16 },
{ -8/16, -8/16, 6/16, 8/16, -6/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ -1/16, -8/16, 6/16, 1/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }},
{{ -8/16, 6/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -3/32, 6/16, 8/16, 1/32, 8/16 },
{ -8/16, -8/16, 6/16, 8/16, -7/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ -1/16, -8/16, 6/16, 1/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }},
{{ -8/16, 7/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -1/32, 6/16, 8/16, 3/32, 8/16 },
{ -8/16, -8/16, 6/16, 8/16, -6/16, 8/16 },
{ -8/16, -8/16, 6/16, -6/16, 8/16, 8/16 },
{ -1/16, -8/16, 6/16, 1/16, 8/16, 8/16 },
{ 6/16, -8/16, 6/16, 8/16, 8/16, 8/16 },
{ -8/16, -8/16, 7/16, 8/16, 8/16, 7/16 }}
},
----------
{
"wood_plain",
"Plain Wooden Door",
{{ -8/16, -8/16, 6/16, 8/16, 8/16, 8/16 }},
{{ -8/16, -8/16, 6/16, 8/16, 8/16, 8/16 }},
{{ -8/16, -8/16, 6/16, 8/16, 8/16, 8/16 }},
{{ -8/16, -8/16, 6/16, 8/16, 8/16, 8/16 }}
},
}