diff --git a/MODSRC/vazkii/botania/common/block/subtile/functional/SubTileAgricarnation.java b/MODSRC/vazkii/botania/common/block/subtile/functional/SubTileAgricarnation.java index 01989dde8..ac126ebab 100644 --- a/MODSRC/vazkii/botania/common/block/subtile/functional/SubTileAgricarnation.java +++ b/MODSRC/vazkii/botania/common/block/subtile/functional/SubTileAgricarnation.java @@ -45,6 +45,7 @@ public class SubTileAgricarnation extends SubTileFunctional { supertile.getWorldObj().scheduleBlockUpdate(x, y, z, block, 1); if(ConfigHandler.blockBreakParticles) supertile.getWorldObj().playAuxSFX(2005, x, y, z, 6 + supertile.getWorldObj().rand.nextInt(4)); + supertile.getWorldObj().playSoundEffect(x, y, z, "botania:agricarnation", 0.1F, 0.5F + (float) Math.random() * 0.5F); break; } diff --git a/MODSRC/vazkii/botania/common/block/subtile/functional/SubtileOrechid.java b/MODSRC/vazkii/botania/common/block/subtile/functional/SubtileOrechid.java index ffde51433..5c145cba8 100644 --- a/MODSRC/vazkii/botania/common/block/subtile/functional/SubtileOrechid.java +++ b/MODSRC/vazkii/botania/common/block/subtile/functional/SubtileOrechid.java @@ -48,6 +48,7 @@ public class SubtileOrechid extends SubTileFunctional { supertile.getWorldObj().setBlock(coords.posX, coords.posY, coords.posZ, block, meta, 1 | 2); if(ConfigHandler.blockBreakParticles) supertile.getWorldObj().playAuxSFX(2001, coords.posX, coords.posY, coords.posZ, Block.getIdFromBlock(block) + (meta << 12)); + supertile.getWorldObj().playSoundEffect(supertile.xCoord, supertile.yCoord, supertile.zCoord, "botania:orechid", 2F, 1F); mana -= COST; sync(); diff --git a/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileEndoflame.java b/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileEndoflame.java index 17bf20675..ea1f8f321 100644 --- a/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileEndoflame.java +++ b/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileEndoflame.java @@ -52,6 +52,7 @@ public class SubTileEndoflame extends SubTileGenerating { this.burnTime = burnTime / 2; stack.stackSize--; + supertile.getWorldObj().playSoundEffect(supertile.xCoord, supertile.yCoord, supertile.zCoord, "botania:endoflame", 0.2F, 1F); if(stack.stackSize == 0) item.setDead(); diff --git a/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileGourmaryllis.java b/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileGourmaryllis.java index 15e33d869..24adbc861 100644 --- a/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileGourmaryllis.java +++ b/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileGourmaryllis.java @@ -50,6 +50,7 @@ public class SubTileGourmaryllis extends SubTileGenerating { int val = ((ItemFood) stack.getItem()).func_150905_g(stack); storedMana = val * val * 18; cooldown = val * 10; + supertile.getWorldObj().playSoundEffect(supertile.xCoord, supertile.yCoord, supertile.zCoord, "random.eat", 0.2F, 0.5F + (float) Math.random() * 0.5F); sync(); } diff --git a/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileHydroangeas.java b/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileHydroangeas.java index 5eb455477..101a7640f 100644 --- a/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileHydroangeas.java +++ b/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileHydroangeas.java @@ -58,6 +58,7 @@ public class SubTileHydroangeas extends SubTileGenerating { supertile.getWorldObj().setBlockToAir(positions[0], supertile.yCoord, positions[1]); didSomething = true; burnTime += getBurnTime(); + playSound(); } if(didSomething) @@ -86,6 +87,10 @@ public class SubTileHydroangeas extends SubTileGenerating { public Block getBlockToSearchBelow() { return null; } + + public void playSound() { + supertile.getWorldObj().playSoundEffect(supertile.xCoord, supertile.yCoord, supertile.zCoord, "random.drink", 0.2F, 0.5F + (float) Math.random() * 0.5F); + } public int getBurnTime() { return 10; diff --git a/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileKekimurus.java b/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileKekimurus.java index d5e52a9f3..98418d483 100644 --- a/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileKekimurus.java +++ b/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileKekimurus.java @@ -41,6 +41,7 @@ public class SubTileKekimurus extends SubTileGenerating { else supertile.getWorldObj().setBlockMetadataWithNotify(x, y, z, meta, 1 | 2); supertile.getWorldObj().playAuxSFX(2001, x, y, z, Block.getIdFromBlock(block) + (meta << 12)); + supertile.getWorldObj().playSoundEffect(supertile.xCoord, supertile.yCoord, supertile.zCoord, "random.eat", 1F, 0.5F + (float) Math.random() * 0.5F); this.mana += mana; sync(); return; diff --git a/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileThermalily.java b/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileThermalily.java index 7c7f19439..e381466e2 100644 --- a/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileThermalily.java +++ b/MODSRC/vazkii/botania/common/block/subtile/generating/SubTileThermalily.java @@ -49,6 +49,11 @@ public class SubTileThermalily extends SubTileHydroangeas { public Block getBlockToSearchBelow() { return ConfigHandler.thermalilyObsidian ? Blocks.obsidian : null; } + + @Override + public void playSound() { + supertile.getWorldObj().playSoundEffect(supertile.xCoord, supertile.yCoord, supertile.zCoord, "botania:thermalily", 0.2F, 1F); + } @Override public int getDelayBetweenPassiveGeneration() { diff --git a/MODSRC/vazkii/botania/common/block/tile/mana/TileSpreader.java b/MODSRC/vazkii/botania/common/block/tile/mana/TileSpreader.java index 34a93c236..48d2aedc1 100644 --- a/MODSRC/vazkii/botania/common/block/tile/mana/TileSpreader.java +++ b/MODSRC/vazkii/botania/common/block/tile/mana/TileSpreader.java @@ -330,6 +330,7 @@ public class TileSpreader extends TileSimpleInventory implements IManaCollector, if(!worldObj.isRemote) { mana -= burst.getStartingMana(); worldObj.spawnEntityInWorld(burst); + worldObj.playSoundEffect(xCoord, yCoord, zCoord, "botania:spreaderFire", 0.2F, 0.7F + 0.3F * (float) Math.random()); } canShootBurst = false; diff --git a/MODSRC/vazkii/botania/common/item/ItemDiviningRod.java b/MODSRC/vazkii/botania/common/item/ItemDiviningRod.java index 8a3d8084a..7b29efeff 100644 --- a/MODSRC/vazkii/botania/common/item/ItemDiviningRod.java +++ b/MODSRC/vazkii/botania/common/item/ItemDiviningRod.java @@ -35,34 +35,36 @@ public class ItemDiviningRod extends ItemMod implements IManaUsingItem { @Override public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer p) { - if(ManaItemHandler.requestManaExact(stack, p, COST, true) && world.isRemote) { - int x = MathHelper.floor_double(p.posX); - int y = MathHelper.floor_double(p.posY); - int z = MathHelper.floor_double(p.posZ); - int range = 15; - long seedxor = world.rand.nextLong(); + if(ManaItemHandler.requestManaExact(stack, p, COST, true)) { + if(world.isRemote) { + int x = MathHelper.floor_double(p.posX); + int y = MathHelper.floor_double(p.posY); + int z = MathHelper.floor_double(p.posZ); + int range = 15; + long seedxor = world.rand.nextLong(); - Botania.proxy.setWispFXDepthTest(false); - for(int i = -range; i < range + 1; i++) - for(int j = -range; j < range + 1; j++) - for(int k = -range; k < range + 1; k++) { - int xp = x + i; - int yp = y + j; - int zp = z + k; - Block block = world.getBlock(xp, yp, zp); - int meta = world.getBlockMetadata(xp, yp, zp); - ItemStack orestack = new ItemStack(block, 1, meta); - for(int id : OreDictionary.getOreIDs(orestack)) { - String s = OreDictionary.getOreName(id); - if(s.matches("^ore.+")) { - Random rand = new Random(s.hashCode() ^ seedxor); - Botania.proxy.wispFX(world, xp + world.rand.nextFloat(), yp + world.rand.nextFloat(), zp + world.rand.nextFloat(), rand.nextFloat(), rand.nextFloat(), rand.nextFloat(), 0.25F, 0F, 8); - break; + Botania.proxy.setWispFXDepthTest(false); + for(int i = -range; i < range + 1; i++) + for(int j = -range; j < range + 1; j++) + for(int k = -range; k < range + 1; k++) { + int xp = x + i; + int yp = y + j; + int zp = z + k; + Block block = world.getBlock(xp, yp, zp); + int meta = world.getBlockMetadata(xp, yp, zp); + ItemStack orestack = new ItemStack(block, 1, meta); + for(int id : OreDictionary.getOreIDs(orestack)) { + String s = OreDictionary.getOreName(id); + if(s.matches("^ore[A-Z].+")) { + Random rand = new Random(s.hashCode() ^ seedxor); + Botania.proxy.wispFX(world, xp + world.rand.nextFloat(), yp + world.rand.nextFloat(), zp + world.rand.nextFloat(), rand.nextFloat(), rand.nextFloat(), rand.nextFloat(), 0.25F, 0F, 8); + break; + } } } - } - Botania.proxy.setWispFXDepthTest(true); - p.swingItem(); + Botania.proxy.setWispFXDepthTest(true); + p.swingItem(); + } else world.playSoundAtEntity(p, "botania:divinationRod", 1F, 1F); } return stack; diff --git a/resources/assets/botania/sounds.json b/resources/assets/botania/sounds.json index bd7ca7c41..f4c508278 100644 --- a/resources/assets/botania/sounds.json +++ b/resources/assets/botania/sounds.json @@ -1,11 +1,14 @@ { "airRod": { "category": "neutral", "sounds":["airRod"] }, + "agricarnation": { "category": "neutral", "sounds":["agricarnation"] }, "altarCraft": { "category": "neutral", "sounds":["altarCraft"] }, "bifrostRod": { "category": "neutral", "sounds":["bifrostRod"] }, "ding": { "category": "neutral", "sounds":["ding"] }, "divaCharm": { "category": "neutral", "sounds":["divaCharm"] }, + "divinationRod": { "category": "neutral", "sounds":["divinationRod"] }, "enchanterBlock": { "category": "neutral", "sounds":["enchanterBlock"] }, "enchanterEnchant": { "category": "neutral", "sounds":["enchanterEnchant"] }, + "endoflame": { "category": "neutral", "sounds":["endoflame"] }, "equipBauble": { "category": "neutral", "sounds":["equipBauble"] }, "gaiaTrap": { "category": "neutral", "sounds":["gaiaTrap"] }, "goldenLaurel": { "category": "neutral", "sounds":["goldenLaurel"] }, @@ -14,10 +17,13 @@ "lexiconPage": { "category": "neutral", "sounds":["lexiconPage"] }, "manaBlaster": { "category": "neutral", "sounds":["manaBlaster"] }, "manaPoolCraft": { "category": "neutral", "sounds":["manaPoolCraft"] }, + "orechid": { "category": "neutral", "sounds":["orechid"] }, "runeAltarCraft": { "category": "neutral", "sounds":["runeAltarCraft"] }, "runeAltarStart": { "category": "neutral", "sounds":["runeAltarStart"] }, + "spreaderFire": { "category": "neutral", "sounds":["spreaderFire"] }, "terraBlade": { "category": "neutral", "sounds":["terraBlade"] }, "terraformRod": { "category": "neutral", "sounds":["terraformRod"] }, "terraPickMode": { "category": "neutral", "sounds":["terraPickMode"] }, - "terrasteelCraft": { "category": "neutral", "sounds":["terrasteelCraft"] } + "terrasteelCraft": { "category": "neutral", "sounds":["terrasteelCraft"] }, + "thermalily": { "category": "neutral", "sounds":["thermalily"] } } \ No newline at end of file diff --git a/resources/assets/botania/sounds/agricarnation.ogg b/resources/assets/botania/sounds/agricarnation.ogg new file mode 100644 index 000000000..4f8af5ee9 Binary files /dev/null and b/resources/assets/botania/sounds/agricarnation.ogg differ diff --git a/resources/assets/botania/sounds/divinationRod.ogg b/resources/assets/botania/sounds/divinationRod.ogg new file mode 100644 index 000000000..006023bf5 Binary files /dev/null and b/resources/assets/botania/sounds/divinationRod.ogg differ diff --git a/resources/assets/botania/sounds/endoflame.ogg b/resources/assets/botania/sounds/endoflame.ogg new file mode 100644 index 000000000..23ffae906 Binary files /dev/null and b/resources/assets/botania/sounds/endoflame.ogg differ diff --git a/resources/assets/botania/sounds/orechid.ogg b/resources/assets/botania/sounds/orechid.ogg new file mode 100644 index 000000000..69ef39d5f Binary files /dev/null and b/resources/assets/botania/sounds/orechid.ogg differ diff --git a/resources/assets/botania/sounds/spreaderFire.ogg b/resources/assets/botania/sounds/spreaderFire.ogg new file mode 100644 index 000000000..b8950cc32 Binary files /dev/null and b/resources/assets/botania/sounds/spreaderFire.ogg differ diff --git a/resources/assets/botania/sounds/thermalily.ogg b/resources/assets/botania/sounds/thermalily.ogg new file mode 100644 index 000000000..371f85354 Binary files /dev/null and b/resources/assets/botania/sounds/thermalily.ogg differ