I'm having a lot of trouble separating materials, base materials, and other materials into database tables with Mysql. I'm working on a crafting section of my game. Basically materials should come from base materials, and some base materials could make other base materials. It's quite difficult for me to sort out.
Materials Table
id, name, type, classification, armourRating, temperature, applicableItems, marketPrice, lowestMarketPrice, highestMarketPrice, token
classification is for (basic, moderate, mastercraft, legendary), temperature is whether the material is warm or cold (leather, or furs), applicableItems (good for armour, good for weapons, good for clothing), token is unique.
Materials Base
id, name, producer, producerType, productionTools, materialToken
producer (sheep, cedar tree, iron ore) producer type (animal, ore) productionTools (shears, pickaxe, bladed), materialToken (from token field above.)
The confusion comes from when I want to produce several things, like furs from pelt, but it can also make leather.
Can someone help me construct my tables better? Thanks for any advice on this.
Edit:
Something that works like this:
Bird
-> Feathers
-> Bone
Animal
-> Pelt -> fur
pelt with fur -> leather or furs
pelt without fur -> leather
-> Bone
Fur -> yarn
Insect
-> silk
Stone
-> Ore -> Metal
Tree
-> Wood -> planks