Swapped reacher functions

thanks temmie
This commit is contained in:
Vaern 2022-01-20 21:31:37 -08:00 committed by GitHub
parent 96d3020daa
commit 046b531e8b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -39,10 +39,10 @@ public class HazardTypeRadiation extends HazardTypeBase {
float rad = level / 20F;
if(GeneralConfig.enable528 && reacher) {
rad = (float) Math.sqrt(rad + 1F / ((rad + 2F) * (rad + 2F))) - 1F / (rad + 2F); //Reworked radiation function: sqrt(x+1/(x+2)^2)-1/(x+2)
rad = (float) (rad / Math.pow(7, 2)); //More realistic function for 528: x / distance^2
} else if(reacher) {
rad = (float) (rad / Math.pow(7, 2)); //More realistic function for normal mode: x / distance^2
} //Distance is 7 here for balancing purposes, realistically it'd be longer and better
rad = (float) Math.sqrt(rad + 1F / ((rad + 2F) * (rad + 2F))) - 1F / (rad + 2F); //Reworked radiation function: sqrt(x+1/(x+2)^2)-1/(x+2)
}
ContaminationUtil.contaminate(target, HazardType.RADIATION, ContaminationType.CREATIVE, rad);
}