|
|
@ -188,8 +188,9 @@ bool API::InitMap()
|
|
|
|
//FIXME: very inadequate
|
|
|
|
//FIXME: very inadequate
|
|
|
|
if (!x_array_loc)
|
|
|
|
if (!x_array_loc)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
throw Error::NoMapLoaded();
|
|
|
|
// bad stuffz happend
|
|
|
|
// bad stuffz happend
|
|
|
|
return false;
|
|
|
|
//return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
uint32_t mx, my, mz;
|
|
|
|
uint32_t mx, my, mz;
|
|
|
|
|
|
|
|
|
|
|
@ -201,7 +202,8 @@ bool API::InitMap()
|
|
|
|
// test for wrong map dimensions
|
|
|
|
// test for wrong map dimensions
|
|
|
|
if (mx == 0 || mx > 48 || my == 0 || my > 48 || mz == 0)
|
|
|
|
if (mx == 0 || mx > 48 || my == 0 || my > 48 || mz == 0)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
return false;
|
|
|
|
throw Error::BadMapDimensions(mx, my);
|
|
|
|
|
|
|
|
//return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// alloc array for pointers to all blocks
|
|
|
|
// alloc array for pointers to all blocks
|
|
|
|