Added bed entity (#3823)

* Added bed entity

* Export cBedEntity to lua
* Set color of bed through item damage value
* Added bed entity to APIDoc
* NBT: Added loading and saving
* Crafting recipes for the colored beds
This commit is contained in:
Lukas Pioch
2017-07-07 09:31:45 +02:00
committed by GitHub
parent 10a3bd9d12
commit 885d828712
28 changed files with 425 additions and 13 deletions
@@ -155,6 +155,46 @@ return
},
Inherits = "cBlockEntityWithItems",
},
cBedEntity =
{
Desc = [[
A bed entity is a {{cBlockEntity}} descendant that represents a bed in the world.
]],
Functions =
{
GetColor =
{
Returns =
{
{
Type = "number",
},
},
Notes = "Returns the color of the bed.",
},
SetColor =
{
Params =
{
{
Type = "number",
},
},
Notes = "Set the color of the bed. A value between 0 - 15. The wool meta color values can be used.",
},
IsPillowBlock =
{
Returns =
{
{
Type = "boolean",
},
},
Notes = "Returns true if this is the pillow block, it has then the meta 8.",
},
},
Inherits = "cBlockEntity",
},
cBlockEntity =
{
Desc = [[