1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-07-17 17:08:39 +00:00

Optionally extend the active object in a players camera direction.

See #6667

By setting active_object_send_range_blocks > active_block_range a server admin
can allow clients to retrieve active objects futher out from the player at
relatively low cost to the server
(only objects in the players' view cone are considered).
This commit is contained in:
Lars Hofhansl 2017-12-03 17:51:58 -08:00
parent 83b12ed481
commit 5a03b1f5f9
2 changed files with 53 additions and 15 deletions

View file

@ -154,8 +154,9 @@ private:
class ActiveBlockList
{
public:
void update(std::vector<v3s16> &active_positions,
s16 radius,
void update(std::vector<PlayerSAO*> &active_players,
s16 active_block_range,
s16 active_object_range,
std::set<v3s16> &blocks_removed,
std::set<v3s16> &blocks_added);
@ -168,6 +169,7 @@ public:
}
std::set<v3s16> m_list;
std::set<v3s16> m_abm_list;
std::set<v3s16> m_forceloaded_list;
private: