Definitely yes. But may I suggest starting from the properties of the finished object?I'm also interested in exploring whether the "material" of an object can automatically be computed from the "ingredients" of the blueprint or vice-versa. That'd be pretty cool - then there would actually be a logical correspondence between the raw material requirements of an item and the properties! You might come to recognize that equipment made from Derpium Ore is generally lighter than the rest (and that would carry over to weapons, armor, etc...anything made of Derpium ) The type system is looking cleaner and cleaner...I just need to keep removing degrees of freedom so that in the end we'll see more patterns and coherence!
Start with the design, either what a player made up in the ship designer or what the procedural generation algorithm cooked up for some NPC faction. That gives you a volume and a surface (I'm assuming for the moment that you can approximate those with some fill algorithm ).
Make up some rules to go from item size to amount of needed material. Something like "5% of the volume of a ship is metal". And then there is the density of the material. Something like "Derpium (the refined metal) has a density of 5.2 g/cm³".
Now lets assume we have a small cargo shuttle roughly the size of the real life Space Shuttle Orbiter. As a very rough estimate, it might have a volume of 600 m³. 5% of that is 30 m³. 30 m³ of Derpium have a weight of 156 tons.
Then we have established one ingredient for the blueprint: 156 tons of Derpium. Assuming we go straight from metal to hull. If you want complex manufacturing chains like in X3, it might be something like
- Ore to hull plates with a volume of 0.1 m³, Derpium hull plates weigh 520kg each based on their volume and the density of Derpium.
- A shuttle is built from 300 hull plates plus several other ingredients
If you feel ambitious, you could allow the player to add armor. Which has a volume based on ship surface multiplied by armor thickness. And a density based on material. And it will add weight to the ship based on volume multiplied by density.
The possibilities are endless, and at some point you will be developing an engineering simulator rather than a space sim