Merge pull request #1407 from CM436/master

Config option to disable cooling tower particle emissions
This commit is contained in:
HbmMods 2024-03-31 22:00:30 +02:00 committed by GitHub
commit 1893aab49c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 5 additions and 2 deletions

View File

@ -34,6 +34,7 @@ public class GeneralConfig {
public static boolean enableFluidContainerCompat = true;
public static boolean enableMOTD = true;
public static boolean enableGuideBook = true;
public static boolean enableSteamParticles = true;
public static int hintPos = 0;
public static boolean enableExpensiveMode = false;
@ -98,7 +99,8 @@ public class GeneralConfig {
enableFluidContainerCompat = config.get(CATEGORY_GENERAL, "1.35_enableFluidContainerCompat", true, "If enabled, fluid containers will be oredicted and interchangable in recipes with other mods' containers, as well as TrainCraft's diesel being considered a valid diesel canister.").getBoolean(true);
enableMOTD = config.get(CATEGORY_GENERAL, "1.36_enableMOTD", true, "If enabled, shows the 'Loaded mod!' chat message as well as update notifications when joining a world").getBoolean(true);
enableGuideBook = config.get(CATEGORY_GENERAL, "1.37_enableGuideBook", true, "If enabled, gives players the guide book when joining the world for the first time").getBoolean(true);
enableSteamParticles = config.get(CATEGORY_GENERAL, "1.38_enableSteamParticles",true, "If disabled, auxiliary cooling towers and large cooling towers will not emit steam particles when in use.").getBoolean(true);
enableExpensiveMode = config.get(CATEGORY_GENERAL, "1.99_enableExpensiveMode", false, "It does what the name implies.").getBoolean(false);
final String CATEGORY_528 = CommonConfig.CATEGORY_528;

View File

@ -55,6 +55,7 @@ import com.hbm.blocks.generic.BlockSnowglobe.TileEntitySnowglobe;
import com.hbm.blocks.machine.MachineFan.TileEntityFan;
import com.hbm.blocks.machine.PistonInserter.TileEntityPistonInserter;
import com.hbm.blocks.machine.WatzPump.TileEntityWatzPump;
import com.hbm.config.GeneralConfig;
import com.hbm.entity.cart.*;
import com.hbm.entity.effect.*;
import com.hbm.entity.grenade.*;
@ -1742,7 +1743,7 @@ public class ClientProxy extends ServerProxy {
}
if("tower".equals(type)) {
if(particleSetting == 0 || (particleSetting == 1 && rand.nextBoolean())) {
if(GeneralConfig.enableSteamParticles && (particleSetting == 0 || (particleSetting == 1 && rand.nextBoolean()))) {
ParticleCoolingTower fx = new ParticleCoolingTower(man, world, x, y, z);
fx.setLift(data.getFloat("lift"));
fx.setBaseScale(data.getFloat("base"));