sound changes, press sounds, remove pitch
This commit is contained in:
parent
c5219ce100
commit
c602585e6a
76 changed files with 231 additions and 251 deletions
|
@ -84,7 +84,7 @@ public class ItemBlock extends Item
|
|||
this.block.onBlockPlacedBy(worldIn, pos, iblockstate1, playerIn, stack);
|
||||
}
|
||||
|
||||
worldIn.playSound(this.block.sound.getPlaceSound(), (double)((float)pos.getX() + 0.5F), (double)((float)pos.getY() + 0.5F), (double)((float)pos.getZ() + 0.5F), (this.block.sound.getVolume() + 1.0F) / 2.0F, this.block.sound.getFrequency() * 0.8F);
|
||||
worldIn.playSound(this.block.sound.getPlaceSound(), (double)((float)pos.getX() + 0.5F), (double)((float)pos.getY() + 0.5F), (double)((float)pos.getZ() + 0.5F), (this.block.sound.getVolume() + 1.0F) / 2.0F);
|
||||
--stack.stackSize;
|
||||
}
|
||||
|
||||
|
|
|
@ -71,7 +71,7 @@ public class ItemBow extends Item
|
|||
}
|
||||
|
||||
stack.damageItem(1, playerIn);
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 1.0F, 1.0F / (itemRand.floatv() * 0.4F + 1.2F) + f * 0.5F);
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 1.0F);
|
||||
|
||||
if (flag)
|
||||
{
|
||||
|
|
|
@ -256,7 +256,7 @@ public class ItemBucket extends Item
|
|||
int i = pos.getX();
|
||||
int j = pos.getY();
|
||||
int k = pos.getZ();
|
||||
worldIn.playSound(SoundEvent.FIZZ, (double)((float)i + 0.5F), (double)((float)j + 0.5F), (double)((float)k + 0.5F), 0.5F, 2.6F + (worldIn.rand.floatv() - worldIn.rand.floatv()) * 0.8F);
|
||||
worldIn.playSound(SoundEvent.FIZZ, (double)((float)i + 0.5F), (double)((float)j + 0.5F), (double)((float)k + 0.5F), 0.5F);
|
||||
|
||||
for (int l = 0; l < 8; ++l)
|
||||
{
|
||||
|
|
|
@ -32,7 +32,7 @@ public class ItemChargedOrb extends ItemFragile
|
|||
if(itemStackIn.getItemDamage() >= this.getMaxDamage())
|
||||
return itemStackIn;
|
||||
itemStackIn.damageItem(1, playerIn);
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F, 0.4F / (itemRand.floatv() * 0.4F + 0.8F));
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F);
|
||||
|
||||
if (!worldIn.client)
|
||||
{
|
||||
|
|
|
@ -31,7 +31,7 @@ public class ItemDie extends Item
|
|||
--itemStackIn.stackSize;
|
||||
// }
|
||||
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F, 0.4F / (itemRand.floatv() * 0.4F + 0.8F));
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F);
|
||||
|
||||
if (!worldIn.client)
|
||||
{
|
||||
|
|
|
@ -30,7 +30,7 @@ public class ItemDynamite extends Item
|
|||
--itemStackIn.stackSize;
|
||||
// }
|
||||
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F, 0.4F / (itemRand.floatv() * 0.4F + 0.8F));
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F);
|
||||
|
||||
if (!worldIn.client)
|
||||
{
|
||||
|
|
|
@ -22,7 +22,7 @@ public class ItemEgg extends Item
|
|||
--itemStackIn.stackSize;
|
||||
// }
|
||||
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F, 0.4F / (itemRand.floatv() * 0.4F + 0.8F));
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F);
|
||||
|
||||
if (!worldIn.client)
|
||||
{
|
||||
|
|
|
@ -27,7 +27,7 @@ public class ItemExpBottle extends Item
|
|||
--itemStackIn.stackSize;
|
||||
// }
|
||||
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F, 0.4F / (itemRand.floatv() * 0.4F + 0.8F));
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F);
|
||||
|
||||
if (!worldIn.client)
|
||||
{
|
||||
|
|
|
@ -19,7 +19,7 @@ public class ItemExterminator extends ItemMagnetic {
|
|||
|
||||
public ItemStack onItemRightClick(ItemStack stack, World world, EntityNPC player) {
|
||||
if(!world.client) {
|
||||
world.playSoundAtEntity(player, SoundEvent.CLICK, 1.0F, 2.0F);
|
||||
world.playSoundAtEntity(player, SoundEvent.CLICK, 1.0F);
|
||||
if(world.dimension == Space.INSTANCE)
|
||||
player.connection.addFeed(TextColor.RED + "Der Weltraum kann nicht zerstört werden (lol)");
|
||||
else if(!((WorldServer)world).exterminate())
|
||||
|
|
|
@ -36,7 +36,7 @@ public class ItemFireball extends Item
|
|||
{
|
||||
if (worldIn.getState(pos).getBlock().getMaterial() == Material.air)
|
||||
{
|
||||
worldIn.playSound(SoundEvent.FIREBALL, (double)pos.getX() + 0.5D, (double)pos.getY() + 0.5D, (double)pos.getZ() + 0.5D, 1.0F, (itemRand.floatv() - itemRand.floatv()) * 0.2F + 1.0F);
|
||||
worldIn.playSound(SoundEvent.FIREBALL, (double)pos.getX() + 0.5D, (double)pos.getY() + 0.5D, (double)pos.getZ() + 0.5D, 1.0F);
|
||||
worldIn.setState(pos, Blocks.fire.getState());
|
||||
}
|
||||
|
||||
|
|
|
@ -48,7 +48,7 @@ public class ItemFishingRod extends Item
|
|||
}
|
||||
else
|
||||
{
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F, 0.4F / (itemRand.floatv() * 0.4F + 0.8F));
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F);
|
||||
|
||||
if (!worldIn.client)
|
||||
{
|
||||
|
|
|
@ -32,7 +32,7 @@ public class ItemFlintAndSteel extends Item
|
|||
{
|
||||
if (worldIn.getState(pos).getBlock().getMaterial() == Material.air)
|
||||
{
|
||||
worldIn.playSound(SoundEvent.IGNITE, (double)pos.getX() + 0.5D, (double)pos.getY() + 0.5D, (double)pos.getZ() + 0.5D, 1.0F, itemRand.floatv() * 0.4F + 0.8F);
|
||||
worldIn.playSound(SoundEvent.IGNITE, (double)pos.getX() + 0.5D, (double)pos.getY() + 0.5D, (double)pos.getZ() + 0.5D, 1.0F);
|
||||
worldIn.setState(pos, Blocks.fire.getState());
|
||||
}
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@ public class ItemFood extends Item
|
|||
{
|
||||
// if(!playerIn.creative)
|
||||
--stack.stackSize;
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.EAT, 0.5F, worldIn.rand.floatv() * 0.1F + 0.9F);
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.EAT, 0.5F);
|
||||
playerIn.heal((int)((float)this.getHealAmount(stack) * 0.5f * (1.0f + worldIn.rand.floatv())));
|
||||
this.onFoodEaten(stack, worldIn, playerIn);
|
||||
// playerIn.triggerAchievement(StatRegistry.objectUseStats[ItemRegistry.getIdFromItem(this)]);
|
||||
|
|
|
@ -56,7 +56,7 @@ public abstract class ItemGunBase extends Item
|
|||
// }
|
||||
|
||||
stack.damageItem(1, playerIn);
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.EXPLODE_ALT, 1.0F, 1.5F);
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.EXPLODE_ALT, 1.0F);
|
||||
|
||||
if(!flag)
|
||||
playerIn.inventory.consumeInventoryItem(this.getAmmo());
|
||||
|
|
|
@ -67,7 +67,7 @@ public class ItemHoe extends Item
|
|||
protected boolean useHoe(ItemStack stack, EntityNPC player, World worldIn, BlockPos target, State newState)
|
||||
{
|
||||
if(newState.getBlock().sound.getStepSound() != null)
|
||||
worldIn.playSound(newState.getBlock().sound.getStepSound(), (double)((float)target.getX() + 0.5F), (double)((float)target.getY() + 0.5F), (double)((float)target.getZ() + 0.5F), (newState.getBlock().sound.getVolume() + 1.0F) / 2.0F, newState.getBlock().sound.getFrequency() * 0.8F);
|
||||
worldIn.playSound(newState.getBlock().sound.getStepSound(), (double)((float)target.getX() + 0.5F), (double)((float)target.getY() + 0.5F), (double)((float)target.getZ() + 0.5F), (newState.getBlock().sound.getVolume() + 1.0F) / 2.0F);
|
||||
|
||||
if (worldIn.client)
|
||||
{
|
||||
|
|
|
@ -151,7 +151,7 @@ public class ItemPotion extends Item
|
|||
--itemStackIn.stackSize;
|
||||
// }
|
||||
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F, 0.4F / (itemRand.floatv() * 0.4F + 0.8F));
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F);
|
||||
|
||||
if (!worldIn.client)
|
||||
{
|
||||
|
|
|
@ -65,7 +65,7 @@ public class ItemReed extends Item
|
|||
iblockstate1.getBlock().onBlockPlacedBy(worldIn, pos, iblockstate1, playerIn, stack);
|
||||
}
|
||||
|
||||
worldIn.playSound(this.block.sound.getPlaceSound(), (double)((float)pos.getX() + 0.5F), (double)((float)pos.getY() + 0.5F), (double)((float)pos.getZ() + 0.5F), (this.block.sound.getVolume() + 1.0F) / 2.0F, this.block.sound.getFrequency() * 0.8F);
|
||||
worldIn.playSound(this.block.sound.getPlaceSound(), (double)((float)pos.getX() + 0.5F), (double)((float)pos.getY() + 0.5F), (double)((float)pos.getZ() + 0.5F), (this.block.sound.getVolume() + 1.0F) / 2.0F);
|
||||
--stack.stackSize;
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -68,7 +68,7 @@ public class ItemSlab extends ItemBlock
|
|||
|
||||
if (worldIn.checkNoEntityCollision(this.slab.getCollisionBoundingBox(worldIn, pos, iblockstate1)) && worldIn.setState(pos, iblockstate1, 3))
|
||||
{
|
||||
worldIn.playSound(this.slab.sound.getPlaceSound(), (double)((float)pos.getX() + 0.5F), (double)((float)pos.getY() + 0.5F), (double)((float)pos.getZ() + 0.5F), (this.slab.sound.getVolume() + 1.0F) / 2.0F, this.slab.sound.getFrequency() * 0.8F);
|
||||
worldIn.playSound(this.slab.sound.getPlaceSound(), (double)((float)pos.getX() + 0.5F), (double)((float)pos.getY() + 0.5F), (double)((float)pos.getZ() + 0.5F), (this.slab.sound.getVolume() + 1.0F) / 2.0F);
|
||||
--stack.stackSize;
|
||||
}
|
||||
|
||||
|
@ -142,7 +142,7 @@ public class ItemSlab extends ItemBlock
|
|||
|
||||
if (worldIn.checkNoEntityCollision(this.slab.getCollisionBoundingBox(worldIn, pos, iblockstate1)) && worldIn.setState(pos, iblockstate1, 3))
|
||||
{
|
||||
worldIn.playSound(this.slab.sound.getPlaceSound(), (double)((float)pos.getX() + 0.5F), (double)((float)pos.getY() + 0.5F), (double)((float)pos.getZ() + 0.5F), (this.slab.sound.getVolume() + 1.0F) / 2.0F, this.slab.sound.getFrequency() * 0.8F);
|
||||
worldIn.playSound(this.slab.sound.getPlaceSound(), (double)((float)pos.getX() + 0.5F), (double)((float)pos.getY() + 0.5F), (double)((float)pos.getZ() + 0.5F), (this.slab.sound.getVolume() + 1.0F) / 2.0F);
|
||||
--stack.stackSize;
|
||||
}
|
||||
|
||||
|
@ -172,7 +172,7 @@ public class ItemSlab extends ItemBlock
|
|||
|
||||
if (worldIn.setState(pos, iblockstate1, 3))
|
||||
{
|
||||
worldIn.playSound(this.slab.sound.getPlaceSound(), (double)((float)pos.getX() + 0.5F), (double)((float)pos.getY() + 0.5F), (double)((float)pos.getZ() + 0.5F), (this.slab.sound.getVolume() + 1.0F) / 2.0F, this.slab.sound.getFrequency() * 0.8F);
|
||||
worldIn.playSound(this.slab.sound.getPlaceSound(), (double)((float)pos.getX() + 0.5F), (double)((float)pos.getY() + 0.5F), (double)((float)pos.getZ() + 0.5F), (this.slab.sound.getVolume() + 1.0F) / 2.0F);
|
||||
--stack.stackSize;
|
||||
}
|
||||
|
||||
|
|
|
@ -55,7 +55,7 @@ public class ItemSnow extends ItemBlock
|
|||
|
||||
if (axisalignedbb != null && worldIn.checkNoEntityCollision(axisalignedbb) && worldIn.setState(blockpos, iblockstate1, 2))
|
||||
{
|
||||
worldIn.playSound(this.block.sound.getPlaceSound(), (double)((float)blockpos.getX() + 0.5F), (double)((float)blockpos.getY() + 0.5F), (double)((float)blockpos.getZ() + 0.5F), (this.block.sound.getVolume() + 1.0F) / 2.0F, this.block.sound.getFrequency() * 0.8F);
|
||||
worldIn.playSound(this.block.sound.getPlaceSound(), (double)((float)blockpos.getX() + 0.5F), (double)((float)blockpos.getY() + 0.5F), (double)((float)blockpos.getZ() + 0.5F), (this.block.sound.getVolume() + 1.0F) / 2.0F);
|
||||
--stack.stackSize;
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -22,7 +22,7 @@ public class ItemSnowball extends Item
|
|||
--itemStackIn.stackSize;
|
||||
// }
|
||||
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F, 0.4F / (itemRand.floatv() * 0.4F + 0.8F));
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.THROW, 0.5F);
|
||||
|
||||
if (!worldIn.client)
|
||||
{
|
||||
|
|
|
@ -21,7 +21,7 @@ public class ItemWeatherToken extends ItemMagnetic {
|
|||
if(worldIn.dimension.getType().weather) {
|
||||
// if (!playerIn.creative)
|
||||
--itemStackIn.stackSize;
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.SPELL, 0.5F, 0.4F / (itemRand.floatv() * 0.4F + 0.8F));
|
||||
worldIn.playSoundAtEntity(playerIn, SoundEvent.SPELL, 0.5F);
|
||||
if (!worldIn.client)
|
||||
{
|
||||
WorldServer world = (WorldServer)worldIn;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue