}
if (tweaks.getTag("doFireTickOut")
.setComment("If set to true and doFireTick is disabled in the game rules, fire will still dissipate if it's not over a fire source")
.getBooleanValue(true)) {
transformer.add(new MethodTransformer(new ObfMapping("net/minecraft/block/BlockFire", "func_149674_a", "(Lnet/minecraft/world/World;IIILjava/util/Random;)V"))
{
@Override
public void transform(MethodNode mv) {
ASMBlock needle = blocks.get("n_doFireTick");
ASMBlock inject = blocks.get("doFireTick");
ASMBlock key = needle.applyLabels(findOnce(mv.instructions, needle.list));
LabelNode jlabel = key.get("LRET");
mv.instructions.insertBefore(jlabel, new JumpInsnNode(GOTO, inject.get("LSKIP")));
mv.instructions.insert(jlabel, inject.list.list);
}
});
}
if (tweaks.getTag("finiteWater")
.setComment("If set to true two adjacent water source blocks will not generate a third.")
.getBooleanValue(false)) {
transformer.add(new MethodTransformer(new ObfMapping("net/minecraft/block/BlockDynamicLiquid", "func_149674_a", "(Lnet/minecraft/world/World;IIILjava/util/Random;)V"))
{
@Override
public void transform(MethodNode mv) {
InsnListSection key = findOnce(mv.instructions, blocks.get("finiteWater").list);
key.setLast(((JumpInsnNode) key.getLast()).label);