Make searing's damage boost uniform, instead of splitting half as fire damage
The reduction is a bit more of a weakness than other traits, so something stronger in the nether at top tier is probably fine
package slimeknights.tconstruct.tools.modifiers.traits;
import net.minecraft.entity.LivingEntity;
-import net.minecraft.entity.player.PlayerEntity;
-import net.minecraft.util.DamageSource;
import net.minecraft.util.math.BlockPos;
import slimeknights.tconstruct.library.materials.MaterialValues;
import slimeknights.tconstruct.library.modifiers.Modifier;
@@ -34,29 +32,6 @@ public class SearingModifier extends Modifier {
@Override
public float applyLivingDamage(IModifierToolStack tool, int level, LivingEntity attacker, LivingEntity target, float baseDamage, float damage, boolean isCritical, boolean fullyCharged) {
BlockPos attackerPos = attacker.getPosition();
- // only decrease damage, increase is handled in afterLivingHit
- float temperature = attacker.world.getBiome(attackerPos).getTemperature(attackerPos);
- if (temperature < BASELINE_TEMPERATURE) {
- damage += temperatureBoost(temperature, level);
- }
- return damage;
- }
-
- @Override
- public int afterLivingHit(IModifierToolStack tool, int level, LivingEntity attacker, LivingEntity target, float damageDealt, boolean isCritical, float cooldown) {
- BlockPos attackerPos = attacker.getPosition();
- // only increase damage, decrease in applyLivingDamage
- float temperature = attacker.world.getBiome(attackerPos).getTemperature(attackerPos);
- if (temperature > BASELINE_TEMPERATURE) {
- DamageSource source;
- if (attacker instanceof PlayerEntity) {
- source = DamageSource.causePlayerDamage((PlayerEntity)attacker);
- } else {
- source = DamageSource.causeMobDamage(attacker);
- }
- target.hurtResistantTime = 0;
- attackEntitySecondary(source.setFireDamage(), temperatureBoost(temperature, level) * cooldown, target, false);
- }
- return 0;
+ return damage + temperatureBoost(attacker.world.getBiome(attackerPos).getTemperature(attackerPos), level);
}
}
