| 281 | |
| 282 | |
| 283 | bool cPluginLua::OnChunkGenerated(cWorld * a_World, int a_ChunkX, int a_ChunkZ, cChunkDesc * a_ChunkDesc) |
| 284 | { |
| 285 | cCSLock Lock(m_CriticalSection); |
| 286 | bool res = false; |
| 287 | cLuaRefs & Refs = m_HookMap[cPluginManager::HOOK_CHUNK_GENERATED]; |
| 288 | for (cLuaRefs::iterator itr = Refs.begin(), end = Refs.end(); itr != end; ++itr) |
| 289 | { |
| 290 | m_LuaState.Call((int)(**itr), a_World, a_ChunkX, a_ChunkZ, a_ChunkDesc, cLuaState::Return, res); |
| 291 | if (res) |
| 292 | { |
| 293 | return true; |
| 294 | } |
| 295 | } |
| 296 | return false; |
| 297 | } |
| 298 | |
| 299 | |
| 300 |
no test coverage detected