mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-14 00:55:20 +02:00
Add function to get all HUD elements (#14042)
This commit is contained in:
@@ -139,6 +139,12 @@ HudElement* Player::getHud(u32 id)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void Player::hudApply(std::function<void(const std::vector<HudElement*>&)> f)
|
||||
{
|
||||
MutexAutoLock lock(m_mutex);
|
||||
f(hud);
|
||||
}
|
||||
|
||||
HudElement* Player::removeHud(u32 id)
|
||||
{
|
||||
MutexAutoLock lock(m_mutex);
|
||||
|
Reference in New Issue
Block a user