Ejemplo n.º 1
0
        private void updatePartResources()
        {
            float resourceScalar = Mathf.Pow(getScale(), thrustScalePower);
            float currentVolume  = resourceVolume * resourceScalar;

            if (!SSTUModInterop.onPartFuelVolumeUpdate(part, currentVolume * 1000))
            {
                SSTUResourceList list = new SSTUResourceList();
                fuelType.addResources(list, currentVolume);
                list.setResourcesToPart(part);
            }
        }
        private void updateResources()
        {
            float scale  = Mathf.Pow(getEngineScale(), thrustScalePower);
            float volume = resourceVolume * scale * numberOfEngines;

            if (!SSTUModInterop.onPartFuelVolumeUpdate(part, volume * 1000))
            {
                SSTUResourceList resources = new SSTUResourceList();
                fuelType.addResources(resources, volume);
                resources.setResourcesToPart(part);
            }
        }