public void onEditorShipModified(ShipConstruct ship) { if (!HighLogic.LoadedSceneIsEditor) { return; } fairingBase.setOpacity(editorTransparency ? 0.25f : 1); }
public void createFairing(Material material, float editorOpacity) { fairingBase.generateColliders = this.generateColliders; fairingBase.facesPerCollider = this.facesPerCollider; fairingBase.clearProfile(); fairingBase.setNumberOfPanels(numOfSections, false); fairingBase.addRing(bottomY, bottomRadius); fairingBase.addRing(topY, topRadius); fairingBase.generateFairing(); fairingBase.setMaterial(material); fairingBase.setOpacity(HighLogic.LoadedSceneIsEditor ? editorOpacity : 1.0f); }