{
	code: "lantern",
	class: "BlockLantern",
	entityClass: "Lantern",
	storageFlags: 257,
	behaviorsByType: { 
		"lantern-small-*": [
			{ name: "GroundStorable", properties: { layout: 'Quadrants', collisionBox: { x1: 0, y1: 0, z1: 0, x2: 1, y2: 0.25, z2: 1 } } },
			{ name: "GroundUnplaceable" }, // The ground storable obsoletes this being a block. Should be an item, but is kept a block for backwards compatibility
			{ name: "Lockable" }, 
			{ name: "OmniAttachable", properties: { 
				facingCode: "position",
				attachmentAreas: {
					"down": { x1: 7, y1: 15, z1: 7, x2: 8, y2: 15, z2: 8 },
					"up": { x1: 4, y1: 0, z1: 4, x2: 11, y2: 0, z2: 11 },
					"north": { x1: 7, y1: 11, z1: 0, x2: 8, y2: 13, z2: 1 },
					"east": { x1: 7, y1: 11, z1: 0, x2: 8, y2: 13, z2: 1, rotateY: 90 },
					"south": { x1: 7, y1: 11, z1: 0, x2: 8, y2: 13, z2: 1, rotateY: 180 },
					"west": { x1: 7, y1: 11, z1: 0, x2: 8, y2: 13, z2: 1, rotateY: 270 },
				},
			}},
			{ name: "RightClickPickup" } 
		],
		"*": [
			{ name: "Lockable" }, 
			{ name: "OmniAttachable", properties: { 
				facingCode: "position",
				attachmentAreas: {
					"down": { x1: 7, y1: 15, z1: 7, x2: 8, y2: 15, z2: 8 },
					"up": { x1: 4, y1: 0, z1: 4, x2: 11, y2: 0, z2: 11 },
					"north": { x1: 7, y1: 11, z1: 0, x2: 8, y2: 13, z2: 1 },
					"east": { x1: 7, y1: 11, z1: 0, x2: 8, y2: 13, z2: 1, rotateY: 90 },
					"south": { x1: 7, y1: 11, z1: 0, x2: 8, y2: 13, z2: 1, rotateY: 180 },
					"west": { x1: 7, y1: 11, z1: 0, x2: 8, y2: 13, z2: 1, rotateY: 270 },
				},
			}},
			{ name: "RightClickPickup" } 
		]
	},
	variantgroups: [
		{ code: "size", states: ["small", "large"] },
		{ code: "position", states: ["up", "down"], loadFromProperties: "abstract/horizontalorientation" }
	],
	shapebytype: {
		"lantern-*-up": { base: "block/metal/lantern/{size}/ground" },
		"lantern-*-down": { base: "block/metal/lantern/{size}/ceiling" },
		"lantern-*-north": { base: "block/metal/lantern/{size}/wall", rotateY: 180 },
		"lantern-*-east": { base: "block/metal/lantern/{size}/wall", rotateY: 90 },
		"lantern-*-south": { base: "block/metal/lantern/{size}/wall", rotateY: 0 },
		"lantern-*-west": { base: "block/metal/lantern/{size}/wall", rotateY: 270 }
	},
	// Must declare textures so they get added to the block texture atlas
	textures: {
		"copper": { base: "block/metal/lantern/copper" },
		"brass": { base: "block/metal/lantern/brass" },
		"blackbronze": { base: "block/metal/lantern/blackbronze" },
		"bismuth": { base: "block/metal/lantern/bismuth" },
		"tinbronze": { base: "block/metal/lantern/tinbronze" },
		"bismuthbronze": { base: "block/metal/lantern/bismuthbronze" },
		"iron": { base: "block/metal/lantern/iron" },
		"molybdochalkos": { base: "block/metal/lantern/molybdochalkos" },
		"silver": { base: "block/metal/lantern/silver" },
		"gold": { base: "block/metal/lantern/gold" },
		"steel": { base: "block/metal/lantern/steel" },
		"meteoriciron": { base: "block/metal/lantern/meteoriciron" },
		"electrum": { base: "block/metal/lantern/electrum" },

		"deco-copper": { base: "block/metal/lantern/copper-deco" },
		"deco-brass": { base: "block/metal/lantern/brass-deco" },
		"deco-blackbronze": { base: "block/metal/lantern/blackbronze-deco" },
		"deco-bismuth": { base: "block/metal/lantern/bismuth-deco" },
		"deco-tinbronze": { base: "block/metal/lantern/tinbronze-deco" },
		"deco-bismuthbronze": { base: "block/metal/lantern/bismuthbronze-deco" },
		"deco-iron": { base: "block/metal/lantern/iron-deco" },
		"deco-molybdochalkos": { base: "block/metal/lantern/molybdochalkos-deco" },
		"deco-silver": { base: "block/metal/lantern/silver-deco" },
		"deco-gold": { base: "block/metal/lantern/gold-deco" },
		"deco-steel": { base: "block/metal/lantern/steel-deco" },
		"deco-meteoriciron": { base: "block/metal/lantern/meteoriciron-deco" },
		"deco-electrum": { base: "block/metal/lantern/electrum-deco" },

		"grid-copper": { base: "block/metal/lantern/grid/copper" },
		"grid-brass": { base: "block/metal/lantern/grid/brass" },
		"grid-blackbronze": { base: "block/metal/lantern/grid/blackbronze" },
		"grid-bismuth": { base: "block/metal/lantern/grid/bismuth" },
		"grid-tinbronze": { base: "block/metal/lantern/grid/tinbronze" },
		"grid-bismuthbronze": { base: "block/metal/lantern/grid/bismuthbronze" },
		"grid-iron": { base: "block/metal/lantern/grid/iron" },
		"grid-molybdochalkos": { base: "block/metal/lantern/grid/molybdochalkos" },
		"grid-silver": { base: "block/metal/lantern/grid/silver" },
		"grid-gold": { base: "block/metal/lantern/grid/gold" },
		"grid-steel": { base: "block/metal/lantern/grid/steel" },
		"grid-meteoriciron": { base: "block/metal/lantern/grid/meteoriciron" },
		"grid-electrum": { base: "block/metal/lantern/grid/electrum" },
	},
	heldRightTpIdleAnimation: "holdinglanternrighthand",
	heldLeftTpIdleAnimation: "holdinglanternlefthand",
	attributes: {
		reinforcable: true
	},
	attributesByType: {
		"*-up": {
			handbook: {
				include: true,
				groupBy: ["lantern-{size}-*"],
				extraSections: [
					{ title: "lantern-handbook-help-title", text: "lantern-handbook-help-text" }
				]
			},
			attachableToEntityByType: {
				"lantern-small-*": {
					categoryCode: "lantern",
					attachedShapeBySlotCode: {
						"Upper Mast Storage": { base: "block/metal/lantern/small/wall" },
						"neck": { base: "item/wearable/hooved/lantern-small-elk" }
					},
					texturePrefixCode: "lantern"
				}
			},	
		},
		"*": {
			handbook: { exclude: true }
		}
	},	
	creativeinventory: {  },
	creativeinventoryStacksByType: {
		"*-up": [
			{
				tabs: [ "general", "decorative" ],
				stacks: [
					{ type: "block", code: "lantern-{size}-up", attributes: { material: "copper", lining: "plain", glass: "quartz" } },
					{ type: "block", code: "lantern-{size}-up", attributes: { material: "brass", lining: "plain", glass: "quartz" } },
					{ type: "block", code: "lantern-{size}-up", attributes: { material: "blackbronze", lining: "plain", glass: "quartz" } },
					{ type: "block", code: "lantern-{size}-up", attributes: { material: "bismuth", lining: "plain", glass: "quartz" } },
					{ type: "block", code: "lantern-{size}-up", attributes: { material: "tinbronze", lining: "plain", glass: "quartz" } },
					{ type: "block", code: "lantern-{size}-up", attributes: { material: "bismuthbronze", lining: "plain", glass: "quartz" } },
					{ type: "block", code: "lantern-{size}-up", attributes: { material: "iron", lining: "plain", glass: "quartz" } },
					{ type: "block", code: "lantern-{size}-up", attributes: { material: "molybdochalkos", lining: "plain", glass: "quartz" } },
					{ type: "block", code: "lantern-{size}-up", attributes: { material: "silver", lining: "plain", glass: "quartz" } },
					{ type: "block", code: "lantern-{size}-up", attributes: { material: "gold", lining: "plain", glass: "quartz" } },
					{ type: "block", code: "lantern-{size}-up", attributes: { material: "steel", lining: "plain", glass: "quartz" } },
					{ type: "block", code: "lantern-{size}-up", attributes: { material: "meteoriciron", lining: "plain", glass: "quartz" } },
					{ type: "block", code: "lantern-{size}-up", attributes: { material: "electrum", lining: "plain", glass: "quartz" } }
				]
			}
		]
	},
	blockmaterial: "Metal",
	lightAbsorption: 0,
	lightHsvByType: {
		"lantern-small-*": [7, 3, 18],
		"lantern-large-*": [7, 3, 20]
	},
	sidesolid: {
		all: false
	},
	sideopaque: {
		all: false
	},
	replaceable: 500,
	resistance: 1,
	guiTransform: {
		origin: { x: 0.5, y: 0.3, z: 0.5 },
		scale: 1.5
	},
	tpHandTransform: {
		translation: { x: -0.6199, y: -0.84, z: -0.93 },
		rotation: { x: 0, y: 7, z: -90 },
		scale: 0.55
	},
	tpOffHandTransform: {
		translation: { x: -0.6899, y: -0.89, z: -0.93 },
		rotation: { x: 0, y: -8, z: -96 },
		scale: 0.55
	},
	groundTransform: {
		origin: { x: 0.5, y: 0, z: 0.5 },
		scale: 3.5
	},
	selectionboxbytype: {
		"*-small-up": { x1: 0.3125, y1: 0, z1: 0.3125, x2: 0.6875, y2: 0.75, z2: 0.6875 },
		"*-small-down": { x1: 0.3125, y1: 0, z1: 0.3125, x2: 0.6875, y2: 1, z2: 0.6875 },
		"*-small-east": { x1: 0.3125, y1: 0.25, z1: 0.5, x2: 0.6875, y2: 0.875, z2: 1, rotateY: 270 },
		"*-small-south": { x1: 0.3125, y1: 0.25, z1: 0.5, x2: 0.6875, y2: 0.875, z2: 1, rotateY: 180 },
		"*-small-west": { x1: 0.3125, y1: 0.25, z1: 0.5, x2: 0.6875, y2: 0.875, z2: 1, rotateY: 90 },
		"*-small-north": { x1: 0.3125, y1: 0.25, z1: 0.5, x2: 0.6875, y2: 0.875, z2: 1, rotateY: 0 },

		"*-large-up": { x1: 0.25, y1: 0, z1: 0.25, x2: 0.75, y2: 0.75, z2: 0.75 },
		"*-large-down": { x1: 0.25, y1: 0, z1: 0.25, x2: 0.75, y2: 1, z2: 0.75 },
		"*-large-east": { x1: 0.25, y1: 0, z1: 0.25, x2: 0.75, y2: 0.875, z2: 1, rotateY: 270 },
		"*-large-south": { x1: 0.25, y1: 0, z1: 0.25, x2: 0.75, y2: 0.875, z2: 1, rotateY: 180 },
		"*-large-west": { x1: 0.25, y1: 0, z1: 0.25, x2: 0.75, y2: 0.875, z2: 1, rotateY: 90 },
		"*-large-north": { x1: 0.25, y1: 0, z1: 0.25, x2: 0.75, y2: 0.875, z2: 1, rotateY: 0 }
	},
	collisionboxbytype: {
		"*-small-up": { x1: 0.3125, y1: 0, z1: 0.3125, x2: 0.6875, y2: 0.75, z2: 0.6875 },
		"*-small-down": { x1: 0.3125, y1: 0, z1: 0.3125, x2: 0.6875, y2: 1, z2: 0.6875 },
		"*-small-east": { x1: 0.3125, y1: 0.25, z1: 0.5, x2: 0.6875, y2: 0.875, z2: 1, rotateY: 270 },
		"*-small-south": { x1: 0.3125, y1: 0.25, z1: 0.5, x2: 0.6875, y2: 0.875, z2: 1, rotateY: 180 },
		"*-small-west": { x1: 0.3125, y1: 0.25, z1: 0.5, x2: 0.6875, y2: 0.875, z2: 1, rotateY: 90 },
		"*-small-north": { x1: 0.3125, y1: 0.25, z1: 0.5, x2: 0.6875, y2: 0.875, z2: 1, rotateY: 0 },

		"*-large-up": { x1: 0.25, y1: 0, z1: 0.25, x2: 0.6875, y2: 0.75, z2: 0.75 },
		"*-large-down": { x1: 0.25, y1: 0, z1: 0.25, x2: 0.75, y2: 1, z2: 0.75 },
		"*-large-east": { x1: 0.25, y1: 0, z1: 0.25, x2: 0.75, y2: 0.875, z2: 1, rotateY: 270 },
		"*-large-south": { x1: 0.25, y1: 0, z1: 0.25, x2: 0.75, y2: 0.875, z2: 1, rotateY: 180 },
		"*-large-west": { x1: 0.25, y1: 0, z1: 0.25, x2: 0.75, y2: 0.875, z2: 1, rotateY: 90 },
		"*-large-north": { x1: 0.25, y1: 0, z1: 0.25, x2: 0.75, y2: 0.875, z2: 1, rotateY: 0 }
	}
}
