Fixed Lua bindings for const objects.

This commit is contained in:
Mattes D
2017-05-09 14:10:53 +02:00
committed by Lukas Pioch
parent 17ba5be852
commit 3d5ee3e5c7
4 changed files with 9 additions and 102 deletions
+2 -1
View File
@@ -605,7 +605,8 @@ bool cPluginLua::OnPlayerFoodLevelChange(cPlayer & a_Player, int a_NewFoodLevel)
bool cPluginLua::OnPlayerFished(cPlayer & a_Player, const cItems & a_Reward)
{
return CallSimpleHooks(cPluginManager::HOOK_PLAYER_FISHED, &a_Player, a_Reward);
cItems reward(a_Reward);
return CallSimpleHooks(cPluginManager::HOOK_PLAYER_FISHED, &a_Player, &reward);
}