Buncha bugfixes [SEE DESC]
Fixed generation values not being written Fixed piston being able to push water Fixed ice creating a non-source block (still doesn't update though) Removed problematic piston codemaster
parent
020ff36af2
commit
303b1a9c45
|
@ -655,7 +655,6 @@ public:
|
|||
g_BlockPistonBreakable[E_BLOCK_IRON_DOOR] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_JACK_O_LANTERN] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_LADDER] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_LAVA] = false;
|
||||
g_BlockPistonBreakable[E_BLOCK_LEVER] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_MELON] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_MELON_STEM] = true;
|
||||
|
@ -668,14 +667,15 @@ public:
|
|||
g_BlockPistonBreakable[E_BLOCK_RED_ROSE] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_REEDS] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_SNOW] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_STATIONARY_LAVA] = false;
|
||||
g_BlockPistonBreakable[E_BLOCK_STATIONARY_WATER] = false; //This gave pistons the ability to drop water :D
|
||||
g_BlockPistonBreakable[E_BLOCK_STATIONARY_LAVA] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_STATIONARY_WATER] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_LAVA] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_WATER] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_STONE_BUTTON] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_STONE_PRESSURE_PLATE] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_TALL_GRASS] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_TORCH] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_VINES] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_WATER] = false;
|
||||
g_BlockPistonBreakable[E_BLOCK_WOODEN_DOOR] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_WOODEN_PRESSURE_PLATE] = true;
|
||||
g_BlockPistonBreakable[E_BLOCK_YELLOW_FLOWER] = true;
|
||||
|
|
|
@ -17,6 +17,12 @@ public:
|
|||
: cBlockHandler(a_BlockType)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
|
||||
virtual void ConvertToPickups(cItems & a_Pickups, NIBBLETYPE a_BlockMeta) override
|
||||
{
|
||||
// No pickups
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@ public:
|
|||
virtual void OnDestroyed(cWorld * a_World, int a_BlockX, int a_BlockY, int a_BlockZ) override
|
||||
{
|
||||
// TODO: Ice destroyed with air below it should turn into air instead of water
|
||||
a_World->FastSetBlock(a_BlockX, a_BlockY, a_BlockZ, E_BLOCK_STATIONARY_WATER, 8);
|
||||
a_World->FastSetBlock(a_BlockX, a_BlockY, a_BlockZ, E_BLOCK_WATER, 0);
|
||||
// This is called later than the real destroying of this ice block
|
||||
}
|
||||
} ;
|
||||
|
|
|
@ -147,7 +147,7 @@ void cComposableGenerator::DoGenerate(int a_ChunkX, int a_ChunkZ, cChunkDesc & a
|
|||
|
||||
void cComposableGenerator::InitBiomeGen(cIniFile & a_IniFile)
|
||||
{
|
||||
AString BiomeGenName = a_IniFile.GetValueSet("Generator", "BiomeGen", "");
|
||||
AString BiomeGenName = a_IniFile.GetValueSet("Generator", "BiomeGen", "MultiStepMap");
|
||||
if (BiomeGenName.empty())
|
||||
{
|
||||
LOGWARN("[Generator]::BiomeGen value not found in world.ini, using \"MultiStepMap\".");
|
||||
|
@ -220,7 +220,7 @@ void cComposableGenerator::InitBiomeGen(cIniFile & a_IniFile)
|
|||
|
||||
void cComposableGenerator::InitHeightGen(cIniFile & a_IniFile)
|
||||
{
|
||||
AString HeightGenName = a_IniFile.GetValueSet("Generator", "HeightGen", "");
|
||||
AString HeightGenName = a_IniFile.GetValueSet("Generator", "HeightGen", "Biomal");
|
||||
if (HeightGenName.empty())
|
||||
{
|
||||
LOGWARN("[Generator]::HeightGen value not found in world.ini, using \"Biomal\".");
|
||||
|
@ -306,7 +306,7 @@ void cComposableGenerator::InitHeightGen(cIniFile & a_IniFile)
|
|||
|
||||
void cComposableGenerator::InitCompositionGen(cIniFile & a_IniFile)
|
||||
{
|
||||
AString CompoGenName = a_IniFile.GetValueSet("Generator", "CompositionGen", "");
|
||||
AString CompoGenName = a_IniFile.GetValueSet("Generator", "CompositionGen", "Biomal");
|
||||
if (CompoGenName.empty())
|
||||
{
|
||||
LOGWARN("[Generator]::CompositionGen value not found in world.ini, using \"Biomal\".");
|
||||
|
|
|
@ -12,11 +12,13 @@
|
|||
#include "Server.h"
|
||||
#include "Blocks/BlockHandler.h"
|
||||
|
||||
/*
|
||||
#ifdef _WIN32
|
||||
#include <windows.h>
|
||||
#else
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
*/
|
||||
|
||||
|
||||
//Athar from http://www.cplusplus.com/forum/unices/60161/ helped with the sleep code.
|
||||
|
@ -128,11 +130,13 @@ void cPiston::ExtendPiston( int pistx, int pisty, int pistz )
|
|||
|
||||
AddDir(extx, exty, extz, pistonMeta & 7, 1)
|
||||
|
||||
/*
|
||||
#ifdef _WIN32
|
||||
Sleep(100);
|
||||
#else
|
||||
usleep(static_cast<useconds_t>(100)*1000);
|
||||
#endif
|
||||
*/
|
||||
|
||||
m_World->SetBlock(extx, exty, extz, E_BLOCK_PISTON_EXTENSION, isSticky + pistonMeta & 7);
|
||||
}
|
||||
|
@ -178,22 +182,26 @@ void cPiston::RetractPiston( int pistx, int pisty, int pistz )
|
|||
// These cannot be moved by the sticky piston, bail out
|
||||
return;
|
||||
}
|
||||
/*
|
||||
#ifdef _WIN32
|
||||
Sleep(100);
|
||||
#else
|
||||
usleep(static_cast<useconds_t>(100)*1000);
|
||||
#endif
|
||||
*/
|
||||
|
||||
m_World->SetBlock(pistx, pisty, pistz, tempblock, tempmeta);
|
||||
m_World->SetBlock(tempx, tempy, tempz, E_BLOCK_AIR, 0);
|
||||
}
|
||||
else
|
||||
{
|
||||
/*
|
||||
#ifdef _WIN32
|
||||
Sleep(100);
|
||||
#else
|
||||
usleep(static_cast<useconds_t>(100)*1000);
|
||||
#endif
|
||||
*/
|
||||
|
||||
m_World->SetBlock(pistx, pisty, pistz, E_BLOCK_AIR, 0);
|
||||
}
|
||||
|
|
|
@ -2476,7 +2476,7 @@ cFluidSimulator * cWorld::InitializeFluidSimulator(cIniFile & a_IniFile, const c
|
|||
Printf(SimulatorNameKey, "%sSimulator", a_FluidName);
|
||||
AString SimulatorSectionName;
|
||||
Printf(SimulatorSectionName, "%sSimulator", a_FluidName);
|
||||
AString SimulatorName = a_IniFile.GetValueSet("Physics", SimulatorNameKey, "");
|
||||
AString SimulatorName = a_IniFile.GetValueSet("Physics", SimulatorNameKey, "Floody");
|
||||
if (SimulatorName.empty())
|
||||
{
|
||||
LOGWARNING("%s [Physics]:%s not present or empty, using the default of \"Floody\".", GetIniFileName().c_str(), SimulatorNameKey.c_str());
|
||||
|
|
Loading…
Reference in New Issue