summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2014-11-27 22:44:02 +0100
committerMattes D <github@xoft.cz>2014-11-27 22:44:02 +0100
commit9f24c0c4da7031776144bc9bf5d9de8f1094334a (patch)
treefa470a74a672177d2817da53d6f60a9c04d73033 /src
parentBlockEntities: Removed the extra semicolon. (diff)
downloadcuberite-9f24c0c4da7031776144bc9bf5d9de8f1094334a.tar
cuberite-9f24c0c4da7031776144bc9bf5d9de8f1094334a.tar.gz
cuberite-9f24c0c4da7031776144bc9bf5d9de8f1094334a.tar.bz2
cuberite-9f24c0c4da7031776144bc9bf5d9de8f1094334a.tar.lz
cuberite-9f24c0c4da7031776144bc9bf5d9de8f1094334a.tar.xz
cuberite-9f24c0c4da7031776144bc9bf5d9de8f1094334a.tar.zst
cuberite-9f24c0c4da7031776144bc9bf5d9de8f1094334a.zip
Diffstat (limited to '')
-rw-r--r--src/Noise/OctavedNoise.h22
1 files changed, 12 insertions, 10 deletions
diff --git a/src/Noise/OctavedNoise.h b/src/Noise/OctavedNoise.h
index 855117289..4af18bd1b 100644
--- a/src/Noise/OctavedNoise.h
+++ b/src/Noise/OctavedNoise.h
@@ -124,18 +124,20 @@ public:
}
// Generate the first octave directly into array:
- const cOctave & FirstOctave = m_Octaves.front();
int ArrayCount = a_SizeX * a_SizeY * a_SizeZ;
- FirstOctave.m_Noise.Generate3D(
- a_Workspace, a_SizeX, a_SizeY, a_SizeZ,
- a_StartX * FirstOctave.m_Frequency, a_EndX * FirstOctave.m_Frequency,
- a_StartY * FirstOctave.m_Frequency, a_EndY * FirstOctave.m_Frequency,
- a_StartZ * FirstOctave.m_Frequency, a_EndZ * FirstOctave.m_Frequency
- );
- NOISE_DATATYPE Amplitude = FirstOctave.m_Amplitude;
- for (int i = 0; i < ArrayCount; i++)
{
- a_Array[i] = a_Workspace[i] * Amplitude;
+ const cOctave & FirstOctave = m_Octaves.front();
+ FirstOctave.m_Noise.Generate3D(
+ a_Workspace, a_SizeX, a_SizeY, a_SizeZ,
+ a_StartX * FirstOctave.m_Frequency, a_EndX * FirstOctave.m_Frequency,
+ a_StartY * FirstOctave.m_Frequency, a_EndY * FirstOctave.m_Frequency,
+ a_StartZ * FirstOctave.m_Frequency, a_EndZ * FirstOctave.m_Frequency
+ );
+ NOISE_DATATYPE Amplitude = FirstOctave.m_Amplitude;
+ for (int i = 0; i < ArrayCount; i++)
+ {
+ a_Array[i] = a_Workspace[i] * Amplitude;
+ }
}
// Add each octave: