Fixed bug in alloy generator