-- require "prototypes.functions"

ORES = {"iron-ore","copper-ore","zinc-ore","lead-ore","tin-ore","tungsten-ore","silver-ore","gold-ore","ardite-ore","cobalt-ore","nickel-ore","quartz-ore","rutile-ore"}

ALLOYS = {
	{
		Name = "invar",
		Recipe = false,
	},
	{
		Name = "solder",
		Recipe = false,
	},
	{
		Name = "brass",
		Recipe = false,
	},
	{
		Name = "bronze",
		Recipe = true,
		Recipe_Category = "melting",
		Recipe_Ingredients = {{type="item", name="copper-plate", amount=4},{type="item", name="tin-plate", amount=1},{type="item", name="zinc-plate", amount=1},{type="fluid", name="lava", amount=1}},
		Recipe_Results = {{type="item", name="bronze-alloy", amount=5}},
	},
	{
		Name = "copper-tungsten",
		Recipe = false,
	},
	{
		Name = "electrum",
		Recipe = false,
	},
	{
		Name = "goloid",
		Recipe = false,
	},
	{
		Name = "ferrophosphorus",
		Recipe = false,
	},
}

RESOURCES = {
	{
		Name = "bauxite",
		Hardness = 2.75,
		Range = 1.1,
		Time = 1.5,
		Color = {r=165, g=42, b=42},
		Result = "stone",
		Amount_Needed = 6,
	},
	{
		Name = "anthracite",
		Hardness = 1.4,
		Range = 1.2,
		Time = 0.5,
		Color = {r=165, g=42, b=42},
		Result = "coal",
		Amount_Needed = 1,
	},
	{
		Name = "chalcopyrite",
		Hardness = 2.3,
		Range = 1.25,
		Time = 0.5,
		Color = {r=181, g=166, b=66},
		Result = "copper-plate",
		Amount_Needed = 4,
		Processing = true,
		Processing_Category = "melting",
		Processing_Ingredients = {{type="item", name="chalcopyrite-ore", amount=2},{type="fluid", name="lava", amount=1}},
		Processing_Results = {{type="item", name="iron-ore", amount=3},{type="item", name="copper-sulfide", amount=2}},
	},
	{
		Name = "chromite",
		Hardness = 5.5,
		Range = 1.05,
		Time = 1.5,
		Color = {r=38, g=38, b=38},
		Result = "stone",
		Amount_Needed = 2,
	},
	{
		Name = "cinnabar",
		Hardness = 3,
		Range = 1.03,
		Time = 1.5,
		Color = {r=255, g=36, b=0},
		Result = "stone",
		Amount_Needed = 3,
	},
	{
		Name = "fluorite",
		Hardness = 4,
		Range = 1.08,
		Time = 1.5,
		Color = {r=255, g=255, b=255},
		Result = "stone",
		Amount_Needed = 4,
	},
	{
		Name = "galena",
		Hardness = 2.5,
		Range = 1.04,
		Time = 1.5,
		Color = {r=166, g=166, b=166},
		Result = "stone",
		Amount_Needed = 5,
	},
	{
		Name = "hematite",
		Hardness = 2.4,
		Range = 1.3,
		Time = 0.5,
		Color = {r=64, g=0, b=0},
		Result = "iron-plate",
		Amount_Needed = 5,
		Processing = true,
		Processing_Category = "roasting",
		Processing_Ingredients = {{type="item", name="hematite-ore", amount=2},{type="fluid", name="lava", amount=1},{type="fluid", name="water", amount=1}},
		Processing_Results = {{type="item", name="iron-ore", amount=3},{type="fluid", name="oxygen", amount=5}},
	},
	{
		Name = "limonite",
		Hardness = 1.8,
		Range = 1.4,
		Time = 0.5,
		Color = {r=140, g=117, b=0},
		Result = "stone",
		Amount_Needed = 1,
		Processing = true,
		Processing_Category = "roasting",
		Processing_Ingredients = {{type="item", name="limonite-ore", amount=4},{type="fluid", name="lava", amount=1},{type="fluid", name="water", amount=1}},
		Processing_Results = {{type="item", name="iron-ore", amount=2},{type="fluid", name="oxygen", amount=3}},
	},
	{
		Name = "magnetite",
		Hardness = 5.5,
		Range = 0.98,
		Time = 1.5,
		Color = {r=26, g=0, b=4},
		Result = "stone",
		Amount_Needed = 4,
		Processing = true,
		Processing_Category = "centrifuge",
		Processing_Ingredients = {{type="item", name="magnetite-ore", amount=4},{type="fluid", name="lava", amount=1},{type="fluid", name="water", amount=1}},
		Processing_Results = {{type="item", name="iron-ore", amount=1},{type="item", name="tungsten-ore", amount=1}},
	},
	{
		Name = "malachite",
		Hardness = 3.75,
		Range = 0.99,
		Time = 1.5,
		Color = {r=80, g=200, b=120},
		Result = "stone",
		Amount_Needed = 7,
	},
	{
		Name = "pyrite",
		Hardness = 6.25,
		Range = 1.01,
		Time = 1.5,
		Color = {r=150, g=25, b=0},
		Result = "stone",
		Amount_Needed = 5,
		Processing = true,
		Processing_Category = "roasting",
		Processing_Ingredients = {{type="item", name="pyrite-ore", amount=2},{type="fluid", name="lava", amount=1},{type="fluid", name="water", amount=1}},
		Processing_Results = {{type="item", name="iron-sulfide", amount=1},{type="item", name="sulfur", amount=3}},
	},
	{
		Name = "sphalerite",
		Hardness = 3.5,
		Range = 1.02,
		Time = 1.5,
		Color = {r=150, g=75, b=0},
		Result = "stone",
		Amount_Needed = 2,
		Processing = true,
		Processing_Category = "centrifuge",
		Processing_Ingredients = {{type="item", name="sphalerite-ore", amount=2},{type="fluid", name="lava", amount=1},{type="fluid", name="water", amount=1}},
		Processing_Results = {{type="item", name="zinc-ore", amount=1},{type="item", name="phosphor", amount=3}},
	},
}

CHEMICALS = {"ammonia","argon","carbon-dioxide","carbon-monoxide","helium","hydrogen","methane","nitric-oxide","nitrogen-dioxide","nitrous-oxide","oxygen","ozone","sulfur-dioxide","sulfur-monoxide","sulfur-trioxide","water","aluminium-hydroxide","sodium-hydroxide"}

INTERMEDIATES = {"charcoal","carbon","silicon","brick","clay","copper-sulfide","phosphor","iron-sulfide","lead-plate","silver-plate","gold-plate","zinc-plate","tin-plate","ardite-plate","cobalt-plate","tungsten-plate"}

MACHINES = {
	{
		Name = "bloomer",
		Machine = true,
		Enabled = true,
		Category = "blooming",
		Tint = {r=0.500, g=0.500, b=0.500},
		Recipe = {{type="item", name="iron-plate", amount=5},{type="item", name="copper-plate", amount=3},{type="item", name="pipe", amount=1}},
	},
	{
		Name = "crystalizer",
		Machine = true,
		Enabled = true,
		Category = "crystalizing",
		Tint = {r=0.500, g=0.500, b=0.500},
		Recipe = {{type="item", name="iron-plate", amount=5},{type="item", name="copper-plate", amount=3},{type="item", name="pipe", amount=1}},
	},
	{
		Name = "melter",
		Machine = true,
		Enabled = true,
		Category = "melting",
		Tint = {r=0.500, g=0.500, b=0.500},
		Recipe = {{type="item", name="iron-plate", amount=5},{type="item", name="copper-plate", amount=3},{type="item", name="pipe", amount=1}},
	},
	{
		Name = "roaster",
		Machine = true,
		Enabled = true,
		Category = "roasting",
		Tint = {r=0.500, g=0.500, b=0.500},
		Recipe = {{type="item", name="iron-plate", amount=5},{type="item", name="copper-plate", amount=3},{type="item", name="pipe", amount=1}},
	},
	{
		Name = "electrolyser",
		Machine = true,
		Enabled = true,
		Category = "electrolys",
		Tint = {r=0.500, g=0.500, b=0.500},
		Recipe = {{type="item", name="iron-plate", amount=5},{type="item", name="copper-plate", amount=3},{type="item", name="pipe", amount=1}},
	},
	{
		Name = "centrifuger",
		Machine = true,
		Enabled = true,
		Category = "centrifuge",
		Tint = {r=0.500, g=0.500, b=0.500},
		Recipe = {{type="item", name="iron-plate", amount=5},{type="item", name="copper-plate", amount=3},{type="item", name="pipe", amount=1}},
	},
	{
		Name = "reducer",
		Machine = true,
		Enabled = true,
		Category = "reduction",
		Tint = {r=0.500, g=0.500, b=0.500},
		Recipe = {{type="item", name="iron-plate", amount=5},{type="item", name="copper-plate", amount=3},{type="item", name="pipe", amount=1}},
	},
	{
		Name = "venting",
		Machine = false,
		Enabled = false,
		Category = "venting",
	},
}