summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-01-28 17:17:26 +0100
committermadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-01-28 17:17:26 +0100
commit05534bbee1b9c920c3181da6ba45e4a6212cf229 (patch)
treeb041a481bd0d43c5470d7c30fec75d365a76966e
parentcItems: Fixed parameter names according to conventions (diff)
downloadcuberite-05534bbee1b9c920c3181da6ba45e4a6212cf229.tar
cuberite-05534bbee1b9c920c3181da6ba45e4a6212cf229.tar.gz
cuberite-05534bbee1b9c920c3181da6ba45e4a6212cf229.tar.bz2
cuberite-05534bbee1b9c920c3181da6ba45e4a6212cf229.tar.lz
cuberite-05534bbee1b9c920c3181da6ba45e4a6212cf229.tar.xz
cuberite-05534bbee1b9c920c3181da6ba45e4a6212cf229.tar.zst
cuberite-05534bbee1b9c920c3181da6ba45e4a6212cf229.zip
Diffstat (limited to '')
-rw-r--r--source/Bindings.cpp12
-rw-r--r--source/Bindings.h2
-rw-r--r--source/Pickup.cpp2
-rw-r--r--source/Plugin.cpp2
-rw-r--r--source/Plugin.h2
-rw-r--r--source/PluginManager.cpp6
-rw-r--r--source/PluginManager.h4
-rw-r--r--source/Plugin_NewLua.cpp6
-rw-r--r--source/Plugin_NewLua.h2
9 files changed, 19 insertions, 19 deletions
diff --git a/source/Bindings.cpp b/source/Bindings.cpp
index e1ede7ebc..fcdf7ac78 100644
--- a/source/Bindings.cpp
+++ b/source/Bindings.cpp
@@ -1,6 +1,6 @@
/*
** Lua binding: AllToLua
-** Generated automatically by tolua++-1.0.92 on 01/27/13 07:29:49.
+** Generated automatically by tolua++-1.0.92 on 01/28/13 17:07:07.
*/
#ifndef __cplusplus
@@ -12709,12 +12709,12 @@ static int tolua_AllToLua_cItems_Add01(lua_State* tolua_S)
cItems* self = (cItems*) tolua_tousertype(tolua_S,1,0);
ENUM_ITEM_ID a_ItemType = ((ENUM_ITEM_ID) (int) tolua_tonumber(tolua_S,2,0));
char a_ItemCount = ((char) tolua_tonumber(tolua_S,3,0));
- short a_ItemHealth = ((short) tolua_tonumber(tolua_S,4,0));
+ short a_ItemDamage = ((short) tolua_tonumber(tolua_S,4,0));
#ifndef TOLUA_RELEASE
if (!self) tolua_error(tolua_S,"invalid 'self' in function 'Add'", NULL);
#endif
{
- self->Add(a_ItemType,a_ItemCount,a_ItemHealth);
+ self->Add(a_ItemType,a_ItemCount,a_ItemDamage);
}
}
return 0;
@@ -12743,12 +12743,12 @@ static int tolua_AllToLua_cItems_Set01(lua_State* tolua_S)
int a_Idx = ((int) tolua_tonumber(tolua_S,2,0));
ENUM_ITEM_ID a_ItemType = ((ENUM_ITEM_ID) (int) tolua_tonumber(tolua_S,3,0));
char a_ItemCount = ((char) tolua_tonumber(tolua_S,4,0));
- short a_ItemHealth = ((short) tolua_tonumber(tolua_S,5,0));
+ short a_ItemDamage = ((short) tolua_tonumber(tolua_S,5,0));
#ifndef TOLUA_RELEASE
if (!self) tolua_error(tolua_S,"invalid 'self' in function 'Set'", NULL);
#endif
{
- self->Set(a_Idx,a_ItemType,a_ItemCount,a_ItemHealth);
+ self->Set(a_Idx,a_ItemType,a_ItemCount,a_ItemDamage);
}
}
return 0;
@@ -21256,7 +21256,7 @@ TOLUA_API int tolua_AllToLua_open (lua_State* tolua_S)
tolua_constant(tolua_S,"HOOK_CHAT",cPluginManager::HOOK_CHAT);
tolua_constant(tolua_S,"HOOK_CHUNK_GENERATED",cPluginManager::HOOK_CHUNK_GENERATED);
tolua_constant(tolua_S,"HOOK_CHUNK_GENERATING",cPluginManager::HOOK_CHUNK_GENERATING);
- tolua_constant(tolua_S,"HOOK_COLLECT_PICKUP",cPluginManager::HOOK_COLLECT_PICKUP);
+ tolua_constant(tolua_S,"HOOK_COLLECTING_PICKUP",cPluginManager::HOOK_COLLECTING_PICKUP);
tolua_constant(tolua_S,"HOOK_CRAFTING_NO_RECIPE",cPluginManager::HOOK_CRAFTING_NO_RECIPE);
tolua_constant(tolua_S,"HOOK_DISCONNECT",cPluginManager::HOOK_DISCONNECT);
tolua_constant(tolua_S,"HOOK_HANDSHAKE",cPluginManager::HOOK_HANDSHAKE);
diff --git a/source/Bindings.h b/source/Bindings.h
index a60564329..e551744f8 100644
--- a/source/Bindings.h
+++ b/source/Bindings.h
@@ -1,6 +1,6 @@
/*
** Lua binding: AllToLua
-** Generated automatically by tolua++-1.0.92 on 01/27/13 07:29:49.
+** Generated automatically by tolua++-1.0.92 on 01/28/13 17:07:08.
*/
/* Exported function */
diff --git a/source/Pickup.cpp b/source/Pickup.cpp
index 1dce2f2ea..ae4db86bb 100644
--- a/source/Pickup.cpp
+++ b/source/Pickup.cpp
@@ -240,7 +240,7 @@ bool cPickup::CollectedBy(cPlayer * a_Dest)
return false; // Not old enough
}
- if (cRoot::Get()->GetPluginManager()->CallHookCollectPickup(a_Dest, *this))
+ if (cRoot::Get()->GetPluginManager()->CallHookCollectingPickup(a_Dest, *this))
{
return false;
}
diff --git a/source/Plugin.cpp b/source/Plugin.cpp
index 0dab44e78..8339d1c7a 100644
--- a/source/Plugin.cpp
+++ b/source/Plugin.cpp
@@ -92,7 +92,7 @@ bool cPlugin::OnChunkGenerating(cWorld * a_World, int a_ChunkX, int a_ChunkZ, cC
-bool cPlugin::OnCollectPickup(cPlayer * a_Player, cPickup * a_Pickup)
+bool cPlugin::OnCollectingPickup(cPlayer * a_Player, cPickup * a_Pickup)
{
UNUSED(a_Player);
UNUSED(a_Pickup);
diff --git a/source/Plugin.h b/source/Plugin.h
index 5988fb7b1..653667171 100644
--- a/source/Plugin.h
+++ b/source/Plugin.h
@@ -52,7 +52,7 @@ public:
virtual bool OnChat (cPlayer * a_Player, const AString & a_Message);
virtual bool OnChunkGenerated (cWorld * a_World, int a_ChunkX, int a_ChunkZ);
virtual bool OnChunkGenerating (cWorld * a_World, int a_ChunkX, int a_ChunkZ, cChunkDesc * a_pLuaChunk);
- virtual bool OnCollectPickup (cPlayer * a_Player, cPickup * a_Pickup);
+ virtual bool OnCollectingPickup (cPlayer * a_Player, cPickup * a_Pickup);
virtual bool OnCraftingNoRecipe (const cPlayer * a_Player, const cCraftingGrid * a_Grid, cCraftingRecipe * a_Recipe);
virtual bool OnDisconnect (cPlayer * a_Player, const AString & a_Reason);
virtual bool OnHandshake (cClientHandle * a_Client, const AString & a_Username);
diff --git a/source/PluginManager.cpp b/source/PluginManager.cpp
index 2fada4714..e7a4329ca 100644
--- a/source/PluginManager.cpp
+++ b/source/PluginManager.cpp
@@ -323,16 +323,16 @@ bool cPluginManager::CallHookChunkGenerating(cWorld * a_World, int a_ChunkX, int
-bool cPluginManager::CallHookCollectPickup(cPlayer * a_Player, cPickup & a_Pickup)
+bool cPluginManager::CallHookCollectingPickup(cPlayer * a_Player, cPickup & a_Pickup)
{
- HookMap::iterator Plugins = m_Hooks.find(HOOK_COLLECT_PICKUP);
+ HookMap::iterator Plugins = m_Hooks.find(HOOK_COLLECTING_PICKUP);
if (Plugins == m_Hooks.end())
{
return false;
}
for (PluginList::iterator itr = Plugins->second.begin(); itr != Plugins->second.end(); ++itr)
{
- if ((*itr)->OnCollectPickup(a_Player, &a_Pickup))
+ if ((*itr)->OnCollectingPickup(a_Player, &a_Pickup))
{
return true;
}
diff --git a/source/PluginManager.h b/source/PluginManager.h
index cbcfb96a2..3a7914b56 100644
--- a/source/PluginManager.h
+++ b/source/PluginManager.h
@@ -50,7 +50,7 @@ public: // tolua_export
HOOK_CHAT,
HOOK_CHUNK_GENERATED,
HOOK_CHUNK_GENERATING,
- HOOK_COLLECT_PICKUP,
+ HOOK_COLLECTING_PICKUP,
HOOK_CRAFTING_NO_RECIPE,
HOOK_DISCONNECT,
HOOK_HANDSHAKE,
@@ -102,7 +102,7 @@ public: // tolua_export
bool CallHookChat (cPlayer * a_Player, const AString & a_Message);
bool CallHookChunkGenerated (cWorld * a_World, int a_ChunkX, int a_ChunkZ);
bool CallHookChunkGenerating (cWorld * a_World, int a_ChunkX, int a_ChunkZ, cChunkDesc * a_Chunk);
- bool CallHookCollectPickup (cPlayer * a_Player, cPickup & a_Pickup);
+ bool CallHookCollectingPickup (cPlayer * a_Player, cPickup & a_Pickup);
bool CallHookCraftingNoRecipe (const cPlayer * a_Player, const cCraftingGrid * a_Grid, cCraftingRecipe * a_Recipe);
bool CallHookDisconnect (cPlayer * a_Player, const AString & a_Reason);
bool CallHookHandshake (cClientHandle * a_ClientHandle, const AString & a_Username);
diff --git a/source/Plugin_NewLua.cpp b/source/Plugin_NewLua.cpp
index c687f6d8c..418c484ad 100644
--- a/source/Plugin_NewLua.cpp
+++ b/source/Plugin_NewLua.cpp
@@ -280,10 +280,10 @@ bool cPlugin_NewLua::OnChunkGenerating(cWorld * a_World, int a_ChunkX, int a_Chu
-bool cPlugin_NewLua::OnCollectPickup(cPlayer * a_Player, cPickup * a_Pickup)
+bool cPlugin_NewLua::OnCollectingPickup(cPlayer * a_Player, cPickup * a_Pickup)
{
cCSLock Lock(m_CriticalSection);
- const char * FnName = GetHookFnName(cPluginManager::HOOK_COLLECT_PICKUP);
+ const char * FnName = GetHookFnName(cPluginManager::HOOK_COLLECTING_PICKUP);
ASSERT(FnName != NULL);
if (!PushFunction(FnName))
{
@@ -1190,7 +1190,7 @@ const char * cPlugin_NewLua::GetHookFnName(cPluginManager::PluginHook a_Hook)
case cPluginManager::HOOK_CHAT: return "OnChat";
case cPluginManager::HOOK_CHUNK_GENERATED: return "OnChunkGenerated";
case cPluginManager::HOOK_CHUNK_GENERATING: return "OnChunkGenerating";
- case cPluginManager::HOOK_COLLECT_PICKUP: return "OnCollectPickup";
+ case cPluginManager::HOOK_COLLECTING_PICKUP: return "OnCollectingPickup";
case cPluginManager::HOOK_CRAFTING_NO_RECIPE: return "OnCraftingNoRecipe";
case cPluginManager::HOOK_DISCONNECT: return "OnDisconnect";
case cPluginManager::HOOK_HANDSHAKE: return "OnHandshake";
diff --git a/source/Plugin_NewLua.h b/source/Plugin_NewLua.h
index 45152e4d7..3e0b33838 100644
--- a/source/Plugin_NewLua.h
+++ b/source/Plugin_NewLua.h
@@ -34,7 +34,7 @@ public:
virtual bool OnChat (cPlayer * a_Player, const AString & a_Message) override;
virtual bool OnChunkGenerated (cWorld * a_World, int a_ChunkX, int a_ChunkZ) override;
virtual bool OnChunkGenerating (cWorld * a_World, int a_ChunkX, int a_ChunkZ, cChunkDesc * a_pLuaChunk ) override;
- virtual bool OnCollectPickup (cPlayer * a_Player, cPickup * a_Pickup) override;
+ virtual bool OnCollectingPickup (cPlayer * a_Player, cPickup * a_Pickup) override;
virtual bool OnCraftingNoRecipe (const cPlayer * a_Player, const cCraftingGrid * a_Grid, cCraftingRecipe * a_Recipe) override;
virtual bool OnDisconnect (cPlayer * a_Player, const AString & a_Reason) override;
virtual bool OnHandshake (cClientHandle * a_Client, const AString & a_Username) override;