public override void OnUpgradeModuleChange(int slotID, TechType techType, bool added) { weapons.upgradeInstalled = modules.GetCount(laserTechType) > 0; drill.upgradeInstalled = modules.GetCount(drillTechType) > 0; bladeControl.upgradeInstalled = modules.GetCount(ramTechType) > 0; if (modules.GetCount(visionTechType) == 0) { SharkVisionControl._enabled = false; UwePostProcessingManager.ToggleBloom(SharkVisionControl.bloomSettingSave); } impactdmg.mirroredSelfDamage = modules.GetCount(ramTechType) == 0; }
public override void OnUpgradeModuleUse(TechType techType, int slotID) { if (techType == visionTechType) { SharkVisionControl._enabled = !SharkVisionControl._enabled; if (SharkVisionControl._enabled) { SharkVisionControl.bloomSettingSave = UwePostProcessingManager.bloomEnabled; UwePostProcessingManager.ToggleBloom(false); } else { UwePostProcessingManager.ToggleBloom(SharkVisionControl.bloomSettingSave); } } else if (techType == blinkTechType) { blink.AttemptBlink(this); } else if (techType == shieldTechType) { shield.active = !shield.active; } }