protected override NewShipComponentOutput[] InnerProcess() { ElementTypes passType = inputs[0].type; float amount = inputs[0].amount; for (int i = 0; i < outputs.Length; i++) { NewShipComponentOutput output = outputs[i]; output.Set(passType, _distribution[i] * amount); } // Change animation params here return(outputs); }
protected override NewShipComponentOutput[] InnerProcess() { ElementTypes passType = inputs[0].type; float amount = inputs[0].amount; for (int i = 0; i < outputs.Length; i++) { NewShipComponentOutput output = outputs[i]; output.Set(passType, _distribution[i] * amount); } string textualDistribution = ""; foreach (float percentage in _distribution) { textualDistribution += (int)(percentage * 100) + "% - "; } SetStatus("Distributing " + amount + " " + passType + " by " + // Removing the extra ' - ' from the distribution text textualDistribution.Substring(0, textualDistribution.Length - 3)); return(outputs); }