Exemplo n.º 1
0
        public double GetAssignedQuality(RepairData repair)         // Making it repair-dependent for further possible features
        {
            if (part.protoModuleCrew.Count == 1)
            {
                ProtoCrewMember kerbal = part.protoModuleCrew[0];

                if (kerbal != null)
                {
                    return(KerbalReconstructionTapeAddon.GetRepairQuality(kerbal.trait, kerbal.experienceLevel));
                }
                else
                {
                    Debug.LogError($"[KRT] Bungler module at part {part.name} has found a null ProtoCrewMember");
                    return(0);
                }
            }
            else
            {
                Debug.LogError($"[KRT] Bungler module has found out that his part {part.name} has not 1 crew member. It seems it is not an EVA Kerbal.");
                return(0);
            }
        }
Exemplo n.º 2
0
        public double GetAssginedWorkPower(RepairData repair)
        {
            if (part.protoModuleCrew.Count == 1)
            {
                ProtoCrewMember kerbal = part.protoModuleCrew[0];

                if (kerbal != null)
                {
                    return(KerbalReconstructionTapeAddon.GetRepairSpeed(kerbal.trait, kerbal.experienceLevel) * KerbalReconstructionTapeAddon.GetRepairQuality(kerbal.trait, kerbal.experienceLevel));
                }
                else
                {
                    Debug.LogError($"[KRT] Bungler module at part {part.name} has found a null ProtoCrewMember");
                    return(0);
                }
            }
            else
            {
                Debug.LogError($"[KRT] Bungler module has found out that his part {part.name} has not 1 crew member. It seems it is not an EVA Kerbal.");
                return(0);
            }
        }