-=*######*==

-########################=
                     =################################+
                  *######################################*
                ############################################
             -################################################=
            ####################################################
          ########################################################
         ############################*=############################
        ###########################...-..###########################+
      *###########################......##*#=########################+
     =#################################:....##########################+
     #####....=+....##.......+#.....##-..##..###.....####........######
    #######..-###..####.=#..*###...##..*####:..##...######..-####-######
   -########..###:..##*.##..*###...#...######...#...######..-###########+
   #########*..##...##.*##.........#...######...#...######......#########
   ##########..=..#..-.###..*###...#...######..:#...######..-############
  +###########...##...####..*###...##...####...##...###:##..-####.#######*
  #############.*###.:###....=#.....###.....:###........#........-########
  ########################################################################
  ############......###*......-##+...:##:..+####..#####....=...###########
  *##########*..######...####=..##-..####.:####....#####..####...#########
   ###########*...*###..######..+#-..####.:####.#..#####..####+..########+
   ##############...##..######..+#-..####.:###.***..####..####+..########
   *#########=####*..#..-####+..##+..####.+##-.###..-###..####..:########
    #########*......###*..##..-####.......##:..###....#....-...##=-#####
    =####################....-#.=######################################=
     *######################*:-########################################
      ###############-*###:-##.#++#+..:#.##.#.*#.##:##...#############
       ##############-*###..##.#++*:##+#.--.#.*#.-*:#.##=############
        *#############**#*##*##*####**##*##*####*#####**###########*
          ########################################################
           *#####################################################
             ##################################################
               ##############################################
                 =########################################=
                    +##################################*
                        +##########################+
                              ################
This commit is contained in:
Lazzzycatwastaken 2025-03-30 19:44:48 +02:00
parent 1ecbc015a3
commit 5c9f6962e2

View File

@ -6,7 +6,11 @@ import com.hbm.blocks.ModBlocks;
import com.hbm.config.ServerConfig;
import com.hbm.explosion.ExplosionLarge;
import com.hbm.explosion.vanillant.ExplosionVNT;
import com.hbm.explosion.vanillant.standard.*;
import com.hbm.explosion.vanillant.standard.BlockAllocatorStandard;
import com.hbm.explosion.vanillant.standard.BlockProcessorStandard;
import com.hbm.explosion.vanillant.standard.EntityProcessorCrossSmooth;
import com.hbm.explosion.vanillant.standard.ExplosionEffectWeapon;
import com.hbm.explosion.vanillant.standard.PlayerProcessorStandard;
import com.hbm.interfaces.IBomb;
import com.hbm.items.ModItems;
import com.hbm.items.weapon.sedna.factory.XFactoryCatapult;
@ -18,7 +22,6 @@ import com.hbm.tileentity.bomb.TileEntityLandmine;
import cpw.mods.fml.common.network.NetworkRegistry.TargetPoint;
import net.minecraft.block.Block;
import net.minecraft.block.BlockContainer;
import net.minecraft.block.BlockDirectional;
import net.minecraft.block.BlockFence;
import net.minecraft.block.material.Material;
import net.minecraft.entity.item.EntityItem;
@ -31,7 +34,6 @@ import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.AxisAlignedBB;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
public class Landmine extends BlockContainer implements IBomb {
@ -175,7 +177,25 @@ public class Landmine extends BlockContainer implements IBomb {
ExplosionLarge.spawnShrapnelShower(world, x + 0.5, y + 0.5, z + 0.5, 0, 1D, 0, 45, 0.2D);
ExplosionLarge.spawnShrapnels(world, x + 0.5, y + 0.5, z + 0.5, 5);
} else if(this == ModBlocks.mine_naval) {
ExplosionVNT vnt = new ExplosionVNT(world, x + 5, y + 5, z + 5, 25F);
vnt.setBlockAllocator(new BlockAllocatorStandard(64));
vnt.setBlockProcessor(new BlockProcessorStandard());
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(0.5, ServerConfig.MINE_NAVAL_DAMAGE.get()).setupPiercing(5F, 0.2F));
vnt.setPlayerProcessor(new PlayerProcessorStandard());
vnt.setSFX(new ExplosionEffectWeapon(10, 1F, 0.5F));
vnt.explode();
ExplosionLarge.spawnParticlesRadial(world, x + 0.5, y + 2, z + 0.5, 30);
ExplosionLarge.spawnRubble(world,x + 0.5, y + 0.5, z + 0.5, 5 );
// Only spawn water effects if there's water above the mine
if (isWaterAbove(world, x, y, z)) {
ExplosionLarge.spawnFoam(world, x + 0.5, y + 0.5, z + 0.5, 60);
}
} else if(this == ModBlocks.mine_fat) {
ExplosionVNT vnt = new ExplosionVNT(world, x + 0.5, y + 0.5, z + 0.5, 10);
vnt.setBlockAllocator(new BlockAllocatorStandard(64));
vnt.setBlockProcessor(new BlockProcessorStandard());
@ -188,22 +208,8 @@ public class Landmine extends BlockContainer implements IBomb {
data.setString("type", "muke");
data.setBoolean("balefire", MainRegistry.polaroidID == 11 || world.rand.nextInt(100) == 0);
PacketDispatcher.wrapper.sendToAllAround(new AuxParticlePacketNT(data, x + 0.5, y + 0.5, z + 0.5), new TargetPoint(world.provider.dimensionId, x + 0.5, y + 0.5, z + 0.5, 250));
} else if(this == ModBlocks.mine_naval) {
ExplosionVNT vnt = new ExplosionVNT(world, x + 5, y + 5, z + 5, 25F);
vnt.setBlockAllocator(new BlockAllocatorStandard(64));
vnt.setBlockProcessor(new BlockProcessorStandard());
vnt.setEntityProcessor(new EntityProcessorCrossSmooth(0.5, ServerConfig.MINE_NAVAL_DAMAGE.get()).setupPiercing(5F, 0.2F));
vnt.setPlayerProcessor(new PlayerProcessorStandard());
vnt.setSFX(new ExplosionEffectWeapon(6, 1F, 0.5F));
vnt.explode();
ExplosionLarge.spawnParticlesRadial(world, x + 0.5, y + 2, z + 0.5, 30);
ExplosionLarge.spawnRubble(world,x + 0.5, y + 0.5, z + 0.5, 5 );
// Only spawn water effects if there's water above the mine
if (isWaterAbove(world, x, y, z)) {
ExplosionLarge.spawnFoam(world, x + 0.5, y + 0.5, z + 0.5, 60);
}
world.playSoundEffect(x + 0.5, y + 0.5, z + 0.5, "hbm:weapon.mukeExplosion", 25.0F, 0.9F); // this has to be the single worst solution ever
}
}