static int deserialization_helper(lua_State *L, AreaStore *as,
std::istream &is)
{
- try {
+ try {
as->deserialize(is);
} catch (const SerializationError &e) {
lua_pushboolean(L, false);
}
const char LuaAreaStore::className[] = "AreaStore";
-const luaL_reg LuaAreaStore::methods[] = {
+const luaL_Reg LuaAreaStore::methods[] = {
luamethod(LuaAreaStore, get_area),
luamethod(LuaAreaStore, get_areas_for_pos),
luamethod(LuaAreaStore, get_areas_in_area),
{
private:
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
static int gc_object(lua_State *L);
}
const char InvRef::className[] = "InvRef";
-const luaL_reg InvRef::methods[] = {
+const luaL_Reg InvRef::methods[] = {
luamethod(InvRef, is_empty),
luamethod(InvRef, get_size),
luamethod(InvRef, set_size),
InventoryLocation m_loc;
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
static InvRef *checkobject(lua_State *L, int narg);
}
const char LuaItemStack::className[] = "ItemStack";
-const luaL_reg LuaItemStack::methods[] = {
+const luaL_Reg LuaItemStack::methods[] = {
luamethod(LuaItemStack, is_empty),
luamethod(LuaItemStack, get_name),
luamethod(LuaItemStack, set_name),
ItemStack m_stack;
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
// Exported functions
}
const char ItemStackMetaRef::className[] = "ItemStackMetaRef";
-const luaL_reg ItemStackMetaRef::methods[] = {
+const luaL_Reg ItemStackMetaRef::methods[] = {
luamethod(MetaDataRef, get_string),
luamethod(MetaDataRef, set_string),
luamethod(MetaDataRef, get_int),
ItemStack *istack;
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
static ItemStackMetaRef *checkobject(lua_State *L, int narg);
}
const char LuaMinimap::className[] = "Minimap";
-const luaL_reg LuaMinimap::methods[] = {
+const luaL_Reg LuaMinimap::methods[] = {
luamethod(LuaMinimap, show),
luamethod(LuaMinimap, hide),
luamethod(LuaMinimap, get_pos),
{
private:
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
// garbage collector
static int gc_object(lua_State *L);
}
-const luaL_reg NodeMetaRef::methodsServer[] = {
+const luaL_Reg NodeMetaRef::methodsServer[] = {
luamethod(MetaDataRef, get_string),
luamethod(MetaDataRef, set_string),
luamethod(MetaDataRef, get_int),
}
-const luaL_reg NodeMetaRef::methodsClient[] = {
+const luaL_Reg NodeMetaRef::methodsClient[] = {
luamethod(MetaDataRef, get_string),
luamethod(MetaDataRef, get_int),
luamethod(MetaDataRef, get_float),
bool m_is_local;
static const char className[];
- static const luaL_reg methodsServer[];
- static const luaL_reg methodsClient[];
+ static const luaL_Reg methodsServer[];
+ static const luaL_Reg methodsClient[];
static NodeMetaRef *checkobject(lua_State *L, int narg);
}
const char NodeTimerRef::className[] = "NodeTimerRef";
-const luaL_reg NodeTimerRef::methods[] = {
+const luaL_Reg NodeTimerRef::methods[] = {
luamethod(NodeTimerRef, start),
luamethod(NodeTimerRef, set),
luamethod(NodeTimerRef, stop),
ServerEnvironment *m_env;
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
static int gc_object(lua_State *L);
const char LuaPerlinNoise::className[] = "PerlinNoise";
-const luaL_reg LuaPerlinNoise::methods[] = {
+const luaL_Reg LuaPerlinNoise::methods[] = {
luamethod(LuaPerlinNoise, get2d),
luamethod(LuaPerlinNoise, get3d),
{0,0}
const char LuaPerlinNoiseMap::className[] = "PerlinNoiseMap";
-const luaL_reg LuaPerlinNoiseMap::methods[] = {
+const luaL_Reg LuaPerlinNoiseMap::methods[] = {
luamethod(LuaPerlinNoiseMap, get2dMap),
luamethod(LuaPerlinNoiseMap, get2dMap_flat),
luamethod(LuaPerlinNoiseMap, calc2dMap),
const char LuaPseudoRandom::className[] = "PseudoRandom";
-const luaL_reg LuaPseudoRandom::methods[] = {
+const luaL_Reg LuaPseudoRandom::methods[] = {
luamethod(LuaPseudoRandom, next),
{0,0}
};
const char LuaPcgRandom::className[] = "PcgRandom";
-const luaL_reg LuaPcgRandom::methods[] = {
+const luaL_Reg LuaPcgRandom::methods[] = {
luamethod(LuaPcgRandom, next),
luamethod(LuaPcgRandom, rand_normal_dist),
{0,0}
}
const char LuaSecureRandom::className[] = "SecureRandom";
-const luaL_reg LuaSecureRandom::methods[] = {
+const luaL_Reg LuaSecureRandom::methods[] = {
luamethod(LuaSecureRandom, next_bytes),
{0,0}
};
private:
NoiseParams np;
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
// Exported functions
Noise *noise;
bool m_is3d;
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
// Exported functions
PseudoRandom m_pseudo;
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
// Exported functions
PcgRandom m_rnd;
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
// Exported functions
private:
static const size_t RAND_BUF_SIZE = 2048;
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
u32 m_rand_idx;
char m_rand_buf[RAND_BUF_SIZE];
}
const char ObjectRef::className[] = "ObjectRef";
-const luaL_reg ObjectRef::methods[] = {
+const luaL_Reg ObjectRef::methods[] = {
// ServerActiveObject
luamethod(ObjectRef, remove),
luamethod_aliased(ObjectRef, get_pos, getpos),
ServerActiveObject *m_object;
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
public:
static ObjectRef *checkobject(lua_State *L, int narg);
}
const char LuaSettings::className[] = "Settings";
-const luaL_reg LuaSettings::methods[] = {
+const luaL_Reg LuaSettings::methods[] = {
luamethod(LuaSettings, get),
luamethod(LuaSettings, get_bool),
luamethod(LuaSettings, set),
{
private:
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
// garbage collector
static int gc_object(lua_State *L);
}
const char StorageRef::className[] = "StorageRef";
-const luaL_reg StorageRef::methods[] = {
+const luaL_Reg StorageRef::methods[] = {
luamethod(MetaDataRef, get_string),
luamethod(MetaDataRef, set_string),
luamethod(MetaDataRef, get_int),
ModMetadata *m_object;
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
virtual Metadata *getmeta(bool auto_create);
virtual void clearMeta();
}
const char LuaVoxelManip::className[] = "VoxelManip";
-const luaL_reg LuaVoxelManip::methods[] = {
+const luaL_Reg LuaVoxelManip::methods[] = {
luamethod(LuaVoxelManip, read_from_map),
luamethod(LuaVoxelManip, get_data),
luamethod(LuaVoxelManip, set_data),
bool is_mapgen_vm;
static const char className[];
- static const luaL_reg methods[];
+ static const luaL_Reg methods[];
static int gc_object(lua_State *L);