From 885d8287125439047ca2318f8e349b8da279e612 Mon Sep 17 00:00:00 2001 From: Lukas Pioch Date: Fri, 7 Jul 2017 09:31:45 +0200 Subject: 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 --- Server/Plugins/APIDump/Classes/BlockEntities.lua | 40 ++++++++++++++++++++++++ 1 file changed, 40 insertions(+) (limited to 'Server/Plugins/APIDump/Classes/BlockEntities.lua') diff --git a/Server/Plugins/APIDump/Classes/BlockEntities.lua b/Server/Plugins/APIDump/Classes/BlockEntities.lua index 5f1289f1e..eac70c1c8 100644 --- a/Server/Plugins/APIDump/Classes/BlockEntities.lua +++ b/Server/Plugins/APIDump/Classes/BlockEntities.lua @@ -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 = [[ -- cgit v1.2.3