summaryrefslogtreecommitdiffstats
path: root/src/Simulator
diff options
context:
space:
mode:
authorJulian Laubstein <julianlaubstein@yahoo.de>2015-11-24 15:43:05 +0100
committerJulian Laubstein <julianlaubstein@yahoo.de>2015-11-24 15:43:05 +0100
commit412e5155a24339aa2a86f36e0ae5a9c5a0ff758d (patch)
treed63858a16962f83d68620bc55c8efeed126874a6 /src/Simulator
parentMerge pull request #2645 from Gargaj/followedarray (diff)
parentAdd enum for Sound and Particle Effects (diff)
downloadcuberite-412e5155a24339aa2a86f36e0ae5a9c5a0ff758d.tar
cuberite-412e5155a24339aa2a86f36e0ae5a9c5a0ff758d.tar.gz
cuberite-412e5155a24339aa2a86f36e0ae5a9c5a0ff758d.tar.bz2
cuberite-412e5155a24339aa2a86f36e0ae5a9c5a0ff758d.tar.lz
cuberite-412e5155a24339aa2a86f36e0ae5a9c5a0ff758d.tar.xz
cuberite-412e5155a24339aa2a86f36e0ae5a9c5a0ff758d.tar.zst
cuberite-412e5155a24339aa2a86f36e0ae5a9c5a0ff758d.zip
Diffstat (limited to 'src/Simulator')
-rw-r--r--src/Simulator/IncrementalRedstoneSimulator.cpp8
-rw-r--r--src/Simulator/SandSimulator.cpp3
2 files changed, 6 insertions, 5 deletions
diff --git a/src/Simulator/IncrementalRedstoneSimulator.cpp b/src/Simulator/IncrementalRedstoneSimulator.cpp
index 43f38584e..fc3dc0a73 100644
--- a/src/Simulator/IncrementalRedstoneSimulator.cpp
+++ b/src/Simulator/IncrementalRedstoneSimulator.cpp
@@ -444,7 +444,7 @@ void cIncrementalRedstoneSimulator::HandleFenceGate(int a_RelBlockX, int a_RelBl
if ((MetaData & 0x4) == 0)
{
m_Chunk->SetMeta(a_RelBlockX, a_RelBlockY, a_RelBlockZ, MetaData | 0x4);
- m_Chunk->BroadcastSoundParticleEffect(1003, BlockX, a_RelBlockY, BlockZ, 0);
+ m_Chunk->BroadcastSoundParticleEffect(EffectID::SFX_RANDOM_DOOR_OPEN_CLOSE, BlockX, a_RelBlockY, BlockZ, 0);
}
SetPlayerToggleableBlockAsSimulated(a_RelBlockX, a_RelBlockY, a_RelBlockZ, true);
}
@@ -456,7 +456,7 @@ void cIncrementalRedstoneSimulator::HandleFenceGate(int a_RelBlockX, int a_RelBl
if ((MetaData & 0x4) != 0)
{
m_Chunk->SetMeta(a_RelBlockX, a_RelBlockY, a_RelBlockZ, MetaData & ~0x04);
- m_Chunk->BroadcastSoundParticleEffect(1003, BlockX, a_RelBlockY, BlockZ, 0);
+ m_Chunk->BroadcastSoundParticleEffect(EffectID::SFX_RANDOM_DOOR_OPEN_CLOSE, BlockX, a_RelBlockY, BlockZ, 0);
}
SetPlayerToggleableBlockAsSimulated(a_RelBlockX, a_RelBlockY, a_RelBlockZ, false);
}
@@ -973,7 +973,7 @@ void cIncrementalRedstoneSimulator::HandleDoor(int a_RelBlockX, int a_RelBlockY,
if (!DoorHandler::IsOpen(ChunkInterface, BlockX, a_RelBlockY, BlockZ))
{
DoorHandler::SetOpen(ChunkInterface, BlockX, a_RelBlockY, BlockZ, true);
- m_Chunk->BroadcastSoundParticleEffect(1003, BlockX, a_RelBlockY, BlockZ, 0);
+ m_Chunk->BroadcastSoundParticleEffect(EffectID::SFX_RANDOM_DOOR_OPEN_CLOSE, BlockX, a_RelBlockY, BlockZ, 0);
}
SetPlayerToggleableBlockAsSimulated(a_RelBlockX, a_RelBlockY, a_RelBlockZ, true);
}
@@ -986,7 +986,7 @@ void cIncrementalRedstoneSimulator::HandleDoor(int a_RelBlockX, int a_RelBlockY,
if (DoorHandler::IsOpen(ChunkInterface, BlockX, a_RelBlockY, BlockZ))
{
DoorHandler::SetOpen(ChunkInterface, BlockX, a_RelBlockY, BlockZ, false);
- m_Chunk->BroadcastSoundParticleEffect(1003, BlockX, a_RelBlockY, BlockZ, 0);
+ m_Chunk->BroadcastSoundParticleEffect(EffectID::SFX_RANDOM_DOOR_OPEN_CLOSE, BlockX, a_RelBlockY, BlockZ, 0);
}
SetPlayerToggleableBlockAsSimulated(a_RelBlockX, a_RelBlockY, a_RelBlockZ, false);
}
diff --git a/src/Simulator/SandSimulator.cpp b/src/Simulator/SandSimulator.cpp
index 70dde8cc0..2ced0cb83 100644
--- a/src/Simulator/SandSimulator.cpp
+++ b/src/Simulator/SandSimulator.cpp
@@ -8,6 +8,7 @@
#include "../Entities/FallingBlock.h"
#include "../Chunk.h"
#include "../IniFile.h"
+#include "../EffectID.h"
@@ -258,7 +259,7 @@ void cSandSimulator::FinishFalling(
a_World->SetBlock(a_BlockX, a_BlockY, a_BlockZ, a_FallingBlockType, a_FallingBlockMeta);
if (a_FallingBlockType == E_BLOCK_ANVIL)
{
- a_World->BroadcastSoundParticleEffect(1022, a_BlockX, a_BlockY, a_BlockZ, 0);
+ a_World->BroadcastSoundParticleEffect(EffectID::SFX_RANDOM_ANVIL_LAND, a_BlockX, a_BlockY, a_BlockZ, 0);
}
return;
}